mirror of https://github.com/CISOfy/lynis.git
Extended YUM test for security plugin testing
This commit is contained in:
parent
510de19ce9
commit
c68b70ff2e
|
@ -643,6 +643,8 @@
|
|||
if [ ${ITEM_FOUND} -eq 1 ]; then
|
||||
DO_TEST=1
|
||||
logtext "Result: found built-in security in yum"
|
||||
else
|
||||
logtext "Result: did not find --security in /usr/share/yum-cli/cli.py"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
@ -653,7 +655,9 @@
|
|||
SearchItem "^enabled=1$" "/etc/yum/pluginconf.d/security.conf"
|
||||
if [ ${ITEM_FOUND} -eq 1 ]; then
|
||||
DO_TEST=1
|
||||
logtext "Result: Found enabled plugin"
|
||||
logtext "Result: found enabled plugin"
|
||||
else
|
||||
logtext "Result: plugin NOT enabled in /etc/yum/pluginconf.d/security.conf"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
@ -672,7 +676,7 @@
|
|||
PACKAGE_AUDIT_TOOL_FOUND=1
|
||||
PACKAGE_AUDIT_TOOL="yum-security"
|
||||
logtext "Test: Checking for vulnerable packages"
|
||||
FIND2=`/usr/bin/yum list-sec security | awk '{ if($2=="security") print $3","$5 }'`
|
||||
FIND2=`/usr/bin/yum list-sec security | awk '{ if($2=="security" || $2~"Sec") print $3","$5 }'`
|
||||
if [ "${FIND2}" = "" ]; then
|
||||
logtext "Result: no vulnerable packages found"
|
||||
Display --indent 2 --text "- Checking missing security packages" --result OK --color GREEN
|
||||
|
|
Loading…
Reference in New Issue