mirror of https://github.com/CISOfy/lynis.git
Check if ipfw is enabled in rc.conf.
This commit is contained in:
parent
5d7dc80481
commit
ded7e95a14
|
@ -280,12 +280,20 @@
|
|||
# For now, only check for IPv4.
|
||||
FIND=`${SYSCTLBINARY} net.inet.ip.fw.enable | awk '{ print $2 }'`
|
||||
if [ "${FIND}" = "1" ]; then
|
||||
Display --indent 4 --text "- Checking ipfw status" --result RUNNING --color GREEN
|
||||
logtext "Result: ipfw is enabled and running for IPv4"
|
||||
Display --indent 2 --text "- Checking ipfw status" --result RUNNING --color GREEN
|
||||
logtext "Result: ipfw is running for IPv4"
|
||||
FIREWALL_ACTIVE=1
|
||||
FIREWALL_SOFTWARE="ipfw"
|
||||
IPFW_ENABLED=`service -e | grep -o ipfw`
|
||||
if [ "${IPFW_ENABLED}" = "ipfw" ]; then
|
||||
Display --indent 4 --text "- ipfw enabled in /etc/rc.conf" --result YES --color GREEN
|
||||
logtext "Result: ipfw is enabled at start-up for IPv4"
|
||||
else
|
||||
Display --indent 4 --text "- ipfw enabled in /etc/rc.conf" --result NO --color YELLOW
|
||||
logtext "Result: ipfw is disabled at start-up for IPv4"
|
||||
fi
|
||||
else
|
||||
Display --indent 4 --text "- Checking ipfw status" --result "NOT RUNNING" --color YELLOW
|
||||
Display --indent 2 --text "- Checking ipfw status" --result "NOT RUNNING" --color YELLOW
|
||||
logtext "Result: ipfw is not running for IPv4"
|
||||
fi
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue