mirror of
https://github.com/CISOfy/lynis.git
synced 2025-07-23 13:54:35 +02:00
Support openSUSE location of sulogin binary
This commit is contained in:
parent
7723f85d5c
commit
3ae5c61839
@ -703,7 +703,7 @@
|
|||||||
if [ -f /usr/lib/systemd/system/rescue.service ]; then
|
if [ -f /usr/lib/systemd/system/rescue.service ]; then
|
||||||
logtext "Result: file /usr/lib/systemd/system/rescue.service"
|
logtext "Result: file /usr/lib/systemd/system/rescue.service"
|
||||||
logtext "Test: checking presence sulogin for single user mode"
|
logtext "Test: checking presence sulogin for single user mode"
|
||||||
FIND=`grep "^ExecStart=-/sbin/sulogin" /usr/lib/systemd/system/rescue.service`
|
FIND=`egrep "^ExecStart=-(/usr)?/sbin/sulogin" /usr/lib/systemd/system/rescue.service`
|
||||||
if [ ! "${FIND}" = "" ]; then
|
if [ ! "${FIND}" = "" ]; then
|
||||||
FOUND=1
|
FOUND=1
|
||||||
logtext "Result: found sulogin, so single user is protected"
|
logtext "Result: found sulogin, so single user is protected"
|
||||||
@ -712,7 +712,7 @@
|
|||||||
logtext "Result: did not find sulogin in rescue.service"
|
logtext "Result: did not find sulogin in rescue.service"
|
||||||
AddHP 1 3
|
AddHP 1 3
|
||||||
Display --indent 2 --text "- Checking sulogin in rescue.service" --result "NOT FOUND" --color YELLOW
|
Display --indent 2 --text "- Checking sulogin in rescue.service" --result "NOT FOUND" --color YELLOW
|
||||||
ReportSuggestion "Protect rescue.service by using sulogin"
|
ReportSuggestion "${TEST_NO}" "Protect rescue.service by using sulogin"
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
logtext "Result: file /usr/lib/systemd/system/rescue.service does not exist"
|
logtext "Result: file /usr/lib/systemd/system/rescue.service does not exist"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user