From 5869fa4eb122076091038951c5e4a7d98b694240 Mon Sep 17 00:00:00 2001 From: Michael Boelen Date: Tue, 16 Jul 2019 14:35:00 +0200 Subject: [INSE-8050] added com.apple.ftp-proxy and improved text output --- include/tests_insecure_services | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'include/tests_insecure_services') diff --git a/include/tests_insecure_services b/include/tests_insecure_services index 25c82626..f9ea8e07 100644 --- a/include/tests_insecure_services +++ b/include/tests_insecure_services @@ -495,16 +495,16 @@ if [ -n "${LAUNCHCTL_BINARY}" ]; then PREQS_MET="YES"; SKIPREASON=""; else PREQS_MET="NO"; SKIPREASON="No launchctl binary on this system"; fi Register --test-no INSE-8050 --os "macOS" --preqs-met ${PREQS_MET} --skip-reason "${SKIPREASON}" --weight M --network NO --category security --description "Check for insecure services on macOS" if [ ${SKIPTEST} -eq 0 ]; then - TEST_SERVICES="com.apple.fingerd" - for ITEM in ${TEST_SERVICES}; do - if ${LAUNCHCTL_BINARY} print-enabled system | ${GREPBINARY} -sq ${ITEM}; then - Display --indent 2 --text "- $text" --result "${STATUS_NO}" --color RED + TEST_SERVICES="com.apple.fingerd com.apple.ftp-proxy" + for ITEM in "${TEST_SERVICES}"; do + if ${LAUNCHCTL_BINARY} list | ${GREPBINARY} -sq ${ITEM}; then + Display --indent 2 --text "- ${ITEM}" --result "${STATUS_NO}" --color RED LogText "Result: found ${ITEM}, which is considered an insecure service" AddSuggestion "${TEST_NO}" "Consider disabling service ${ITEM}" "launchctl" "-" AddHP 0 1 else - Display --indent 2 --text "- $text" --result "${STATUS_OK}" --color GREEN - LogText "Result: $text, OK" + Display --indent 2 --text "- ${ITEM}" --result "${STATUS_OK}" --color GREEN + LogText "Result: did not find ${ITEM}, which is fine" AddHP 1 1 fi done -- cgit v1.2.3