mirror of https://github.com/CISOfy/lynis.git
More style and text changes, and removed warning
This commit is contained in:
parent
1b3cdb9883
commit
23e400ea9e
|
@ -194,29 +194,28 @@
|
|||
#################################################################################
|
||||
#
|
||||
# Test : AUTH-9222
|
||||
# Description : Check for non unique groups
|
||||
Register --test-no AUTH-9222 --weight L --network NO --category security --description "Check for non unique groups"
|
||||
# Description : Check unique group IDs
|
||||
Register --test-no AUTH-9222 --weight L --network NO --category security --description "Check unique groups (IDs)"
|
||||
if [ ${SKIPTEST} -eq 0 ]; then
|
||||
LogText "Test: Checking for non unique group ID's in /etc/group"
|
||||
FIND=`grep -v '^#' /etc/group | grep -v '^$' | awk -F: '{ print $3 }' | sort | uniq -d`
|
||||
FIND=$(grep -v '^#' /etc/group | grep -v '^$' | awk -F: '{ print $3 }' | sort | uniq -d)
|
||||
if [ "${FIND}" = "" ]; then
|
||||
Display --indent 2 --text "- Checking non unique group ID's" --result "${STATUS_OK}" --color GREEN
|
||||
Display --indent 2 --text "- Unique group IDs" --result "${STATUS_OK}" --color GREEN
|
||||
LogText "Result: All group ID's are unique"
|
||||
else
|
||||
Display --indent 2 --text "- Checking non unique group ID's" --result "${STATUS_WARNING}" --color RED
|
||||
else
|
||||
Display --indent 2 --text "- Unique group IDs" --result "${STATUS_WARNING}" --color RED
|
||||
LogText "Result: Found the same group ID multiple times"
|
||||
LogText "Output: ${FIND}"
|
||||
ReportWarning ${TEST_NO} "H" "Found multiple groups with same group ID"
|
||||
#ReportSuggestion ${TEST_NO} "Check your /etc/group file and correct inconsistencies"
|
||||
ReportSuggestion ${TEST_NO} "Check your /etc/group file and correct any inconsistencies"
|
||||
fi
|
||||
fi
|
||||
#
|
||||
#################################################################################
|
||||
#
|
||||
# Test : AUTH-9226
|
||||
# Description : Check non unique group names
|
||||
# Description : Check unique group names
|
||||
if [ -f /etc/group ]; then PREQS_MET="YES"; else PREQS_MET="NO"; fi
|
||||
Register --test-no AUTH-9226 --preqs-met ${PREQS_MET} --weight L --network NO --category security --description "Check non unique group names"
|
||||
Register --test-no AUTH-9226 --preqs-met ${PREQS_MET} --weight L --network NO --category security --description "Check unique group names"
|
||||
if [ ${SKIPTEST} -eq 0 ]; then
|
||||
LogText "Test: Checking for non unique group names in /etc/group"
|
||||
FIND=$(grep -v '^#' /etc/group | grep -v '^$' | awk -F: '{ print $1 }' | sort | uniq -d)
|
||||
|
|
Loading…
Reference in New Issue