mirror of
https://github.com/CISOfy/lynis.git
synced 2025-07-30 01:04:39 +02:00
[functions] ParseNginx: Support include on absolute paths
Includes can be absolute paths too. This is quick fix counting on fact that absolute paths have slash at start.
This commit is contained in:
parent
6355360972
commit
de18ddc2c0
@ -2305,7 +2305,8 @@
|
||||
# Check for additional config files included as follows
|
||||
# "include sites-enabled/*.conf"
|
||||
elif [ $(echo ${VALUE} | grep -F -c "*.conf") -gt 0 ]; then
|
||||
for FOUND_CONF in $(ls ${CONFIG_FILE%nginx.conf}${VALUE%;*}); do
|
||||
if [ "$(echo ${VALUE} | ${CUTBINARY} -c1)" != "/" ]; then VALUE=${CONFIG_FILE%nginx.conf}; fi
|
||||
for FOUND_CONF in $(ls ${VALUE%;*}); do
|
||||
FOUND=0
|
||||
for CONF in ${NGINX_CONF_FILES}; do
|
||||
if [ "${CONF}" = "${FOUND_CONF}" ]; then FOUND=1; LogText "Found this file already in our configuration files array, not adding to queue"; fi
|
||||
|
Loading…
x
Reference in New Issue
Block a user