Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/CISOfy/lynis.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas CARPi <nicolas.carpi@curie.fr>2020-03-05 23:42:54 +0300
committerNicolas CARPi <nicolas.carpi@curie.fr>2020-03-05 23:42:54 +0300
commit600cb84310b0b97aad7184b5224fdc3ba18a04be (patch)
tree6c575ecab6df87946671d6bc633a033eaf608c7a /include/tests_php
parent0593c69f2f434e79c5e3af1cdd1e5e0ffd714543 (diff)
Use a POSIX implementation to check for substring
This works with all shells, even busybox.
Diffstat (limited to 'include/tests_php')
-rw-r--r--include/tests_php6
1 files changed, 5 insertions, 1 deletions
diff --git a/include/tests_php b/include/tests_php
index 6e4d44f9..120b7dcb 100644
--- a/include/tests_php
+++ b/include/tests_php
@@ -292,7 +292,11 @@
FOUND=0
for FILE in ${PHPINI_ALLFILES}; do
# Don't look at this setting in cli configuration
- if [[ ${FILE} == *"/cli/"* ]]; then continue; fi
+ case "${FILE}" in
+ */cli/*)
+ continue
+ ;;
+ esac
LogText "Test: Checking file ${FILE}"
FIND=$(${EGREPBINARY} -i 'expose_php.*(on|yes|1)' ${FILE} | ${GREPBINARY} -v '^;')
if HasData "${FIND}"; then