SV-268451r1131208_rule
V-268451
SRG-OS-000064-GPOS-00033
APPL-15-000190
CAT II
10
Configure the macOS system to log privilege escalation with the following command:
/usr/bin/find /etc/sudoers* -type f -exec sed -i '' '/^Defaults[[:blank:]]*\!log_allowed/s/^/# /' '{}' \;
/bin/echo "Defaults log_allowed" >> /etc/sudoers.d/mscp
Verify the macOS system is configured to log privilege escalation with the following command:
/usr/bin/sudo /usr/bin/sudo -V | /usr/bin/grep -c "Log when a command is allowed by sudoers"
If the result is not "1", this is a finding.
V-268451
False
APPL-15-000190
Verify the macOS system is configured to log privilege escalation with the following command:
/usr/bin/sudo /usr/bin/sudo -V | /usr/bin/grep -c "Log when a command is allowed by sudoers"
If the result is not "1", this is a finding.
M
5661