From 533a0631e7f31c24bb909fc8c82098379703561e Mon Sep 17 00:00:00 2001 From: Michael Boelen Date: Mon, 31 Dec 2018 10:03:26 +0100 Subject: [PATCH] Remove unneeded variable for firewall as data is stored in report --- include/tests_firewalls | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/include/tests_firewalls b/include/tests_firewalls index ee47e70d..8d90e621 100644 --- a/include/tests_firewalls +++ b/include/tests_firewalls @@ -32,7 +32,6 @@ IPTABLES_MODULE_ACTIVE=0 FIREWALL_ACTIVE=0 FIREWALL_EMPTY_RULESET=0 - FIREWALL_SOFTWARE="" NFTABLES_ACTIVE=0 # ################################################################################# @@ -44,7 +43,6 @@ FIND=$(${LSMODBINARY} | ${AWKBINARY} '{ print $1 }' | ${GREPBINARY} "^ip*_tables") if [ ! -z "${FIND}" ]; then FIREWALL_ACTIVE=1 - FIREWALL_SOFTWARE="iptables" IPTABLES_ACTIVE=1 IPTABLES_MODULE_ACTIVE=1 Display --indent 2 --text "- Checking iptables kernel module" --result "${STATUS_FOUND}" --color GREEN @@ -56,7 +54,6 @@ done elif [ -f ${ROOTDIR}proc/net/ip_tables_names ]; then FIREWALL_ACTIVE=1 - FIREWALL_SOFTWARE="iptables" Report "firewall_software[]=iptables" IPTABLES_ACTIVE=1 Display --indent 2 --text "- Checking iptables support" --result "${STATUS_FOUND}" --color GREEN @@ -89,7 +86,6 @@ IPTABLES_ACTIVE=1 IPTABLES_INKERNEL_ACTIVE=1 FIREWALL_ACTIVE=1 - FIREWALL_SOFTWARE="iptables" Display --indent 2 --text "- Checking iptables in config file" --result "${STATUS_FOUND}" --color GREEN else LogText "Result: no iptables found in Linux kernel config file" @@ -262,7 +258,6 @@ if [ ${PFFOUND} -eq 1 ]; then FIREWALL_ACTIVE=1 - FIREWALL_SOFTWARE="pf" Report "firewall_software[]=pf" else LogText "Result: pf not running on this system" @@ -311,7 +306,6 @@ if [ -f ${FILE} ]; then LogText "Result: ${FILE} exists" FIREWALL_ACTIVE=1 - FIREWALL_SOFTWARE="csf" Report "firewall_software[]=csf" Display --indent 2 --text "- Checking CSF status (configuration file)" --result "${STATUS_FOUND}" --color GREEN @@ -346,7 +340,6 @@ Display --indent 4 --text "- Checking ipf status" --result "${STATUS_RUNNING}" --color GREEN LogText "Result: ipf is enabled and running" FIREWALL_ACTIVE=1 - FIREWALL_SOFTWARE="ipf" Report "firewall_software[]=ipf" else Display --indent 4 --text "- Checking ipf status" --result "${STATUS_NOT_RUNNING}" --color YELLOW @@ -367,7 +360,6 @@ Display --indent 2 --text "- Checking IPFW status" --result "${STATUS_RUNNING}" --color GREEN LogText "Result: IPFW is running for IPv4" FIREWALL_ACTIVE=1 - FIREWALL_SOFTWARE="ipfw" Report "firewall_software[]=ipfw" IPFW_ENABLED=$(service -e | ${GREPBINARY} -o ipfw) if [ "${IPFW_ENABLED}" = "ipfw" ]; then @@ -488,7 +480,6 @@ FIND=$(${LSMODBINARY} | ${AWKBINARY} '{ print $1 }' | ${GREPBINARY} "^nf*_tables") if [ ! -z "${FIND}" ]; then LogText "Result: found nftables kernel module" - FIREWALL_SOFTWARE="nftables" FIREWALL_ACTIVE=1 NFTABLES_ACTIVE=1 Report "firewall_software[]=nftables" @@ -579,7 +570,6 @@ if [ -f ${FILE} ]; then LogText "Result: ${FILE} exists" FIREWALL_ACTIVE=1 - FIREWALL_SOFTWARE="apf" Report "firewall_software[]=apf" Display --indent 2 --text "- Checking APF status (configuration file)" --result "${STATUS_FOUND}" --color GREEN @@ -610,7 +600,6 @@ Report "firewall_active=${FIREWALL_ACTIVE}" Report "firewall_empty_ruleset=${FIREWALL_EMPTY_RULESET}" Report "firewall_installed=${FIREWALL_ACTIVE}" -Report "firewall_software=${FIREWALL_SOFTWARE}" WaitForKeyPress