mirror of
https://github.com/CISOfy/lynis.git
synced 2025-07-30 09:14:18 +02:00
Test for presence php.ini file
This commit is contained in:
parent
d56d33a63d
commit
209e1991d2
@ -128,12 +128,16 @@
|
||||
# Description : Check php register_globals option
|
||||
# Notes : Don't test for it if PHP version is 5.4.0 or later (it has been removed)
|
||||
if [ ! "${PHPINIFILE}" = "" -a ! "${PHPVERSION}" = "" -a ! "${EGREPBINARY}" = "" ]; then
|
||||
if [ -f "${PHPINIFILE}" ]; then
|
||||
FIND=`echo ${PHPVERSION} | ${EGREPBINARY} "^(4.|5.[0-3])"`
|
||||
if [ "${FIND}" = "" ]; then
|
||||
PREQS_MET="NO"; Debug "Found most likely PHP version 5.4.0 or higher (${PHPVERSION}) which does not use register_globals"
|
||||
else
|
||||
PREQS_MET="YES"; Debug "Found PHP version 4 or up to 5.3 (${FIND}) which we are going to scan"
|
||||
fi
|
||||
else
|
||||
Debug "File php.ini (${PHPINIFILE}) not found"
|
||||
fi
|
||||
else
|
||||
PREQS_MET="NO"
|
||||
Debug "Skipping test: php.ini not found, or PHP version empty"
|
||||
|
Loading…
x
Reference in New Issue
Block a user