mirror of https://github.com/CISOfy/lynis.git
Change text of AppArmor test and add more details to report
This commit is contained in:
parent
5debe001f1
commit
c061d31bde
|
@ -61,6 +61,8 @@
|
||||||
MAC_FRAMEWORK_ACTIVE=1
|
MAC_FRAMEWORK_ACTIVE=1
|
||||||
LogText "Result: AppArmor is enabled and a policy is loaded"
|
LogText "Result: AppArmor is enabled and a policy is loaded"
|
||||||
Display --indent 4 --text "- Checking AppArmor status" --result "${STATUS_ENABLED}" --color GREEN
|
Display --indent 4 --text "- Checking AppArmor status" --result "${STATUS_ENABLED}" --color GREEN
|
||||||
|
Report "apparmor_enabled=1"
|
||||||
|
Report "apparmor_policy_loaded=1"
|
||||||
elif [ ${FIND} -eq 4 ]; then
|
elif [ ${FIND} -eq 4 ]; then
|
||||||
LogText "Result: Can not determine status, most likely due to lacking permissions"
|
LogText "Result: Can not determine status, most likely due to lacking permissions"
|
||||||
Display --indent 4 --text "- Checking AppArmor status" --result "${STATUS_UNKNOWN}" --color RED
|
Display --indent 4 --text "- Checking AppArmor status" --result "${STATUS_UNKNOWN}" --color RED
|
||||||
|
@ -69,11 +71,14 @@
|
||||||
Display --indent 4 --text "- Checking AppArmor status" --result "${STATUS_UNKNOWN}" --color RED
|
Display --indent 4 --text "- Checking AppArmor status" --result "${STATUS_UNKNOWN}" --color RED
|
||||||
elif [ ${FIND} -eq 2 ]; then
|
elif [ ${FIND} -eq 2 ]; then
|
||||||
LogText "Result: AppArmor is enabled, but no policy is loaded"
|
LogText "Result: AppArmor is enabled, but no policy is loaded"
|
||||||
ReportSuggestion ${TEST_NO} "Disable AppArmor or load a policy"
|
ReportSuggestion ${TEST_NO} "Load AppArmor policies"
|
||||||
Display --indent 4 --text "- Checking AppArmor status" --result "NON-ACTIVE" --color GREEN
|
Display --indent 4 --text "- Checking AppArmor status" --result "NON-ACTIVE" --color GREEN
|
||||||
|
Report "apparmor_enabled=1"
|
||||||
|
Report "apparmor_policy_loaded=0"
|
||||||
elif [ ${FIND} -eq 1 ]; then
|
elif [ ${FIND} -eq 1 ]; then
|
||||||
LogText "Result: AppArmor is disabled"
|
LogText "Result: AppArmor is disabled"
|
||||||
Display --indent 4 --text "- Checking AppArmor status" --result "${STATUS_DISABLED}" --color YELLOW
|
Display --indent 4 --text "- Checking AppArmor status" --result "${STATUS_DISABLED}" --color YELLOW
|
||||||
|
Report "apparmor_enabled=0"
|
||||||
else
|
else
|
||||||
Display --indent 4 --text "- Checking AppArmor status" --result "${STATUS_UNKNOWN}" --color RED
|
Display --indent 4 --text "- Checking AppArmor status" --result "${STATUS_UNKNOWN}" --color RED
|
||||||
ReportException "${TEST_NO}:1" "Invalid or unknown AppArmor status detected"
|
ReportException "${TEST_NO}:1" "Invalid or unknown AppArmor status detected"
|
||||||
|
|
Loading…
Reference in New Issue