SV-269135r1050017_rule
V-269135
SRG-OS-000004-GPOS-00004
ALMA-09-006070
CAT II
10
Configure AlmaLinux OS 9 to generate audit records for all account creations, modifications, disabling, and termination events that affect "/etc/sudoers.d/.
Add the following to the "/etc/audit/rules.d/audit.rules" file:
-w /etc/sudoers.d/ -p wa -k identity
Merge the rules into /etc/audit/audit.rules:
$ augenrules --load
Reboot the server so the changes to take effect.
Verify AlmaLinux OS 9 generates audit records for all account creations, modifications, disabling, and termination events that affect the files within "/etc/sudoers.d/", with the following command:
$ grep /etc/sudoers.d/ /etc/audit/audit.rules
-w /etc/sudoers.d/ -p wa -k identity
If the command does not return a line or the line is commented out, this is a finding.
Note: The "-k" allows for specifying an arbitrary identifier, and the string after it does not need to match the example output above.
V-269135
False
ALMA-09-006070
Verify AlmaLinux OS 9 generates audit records for all account creations, modifications, disabling, and termination events that affect the files within "/etc/sudoers.d/", with the following command:
$ grep /etc/sudoers.d/ /etc/audit/audit.rules
-w /etc/sudoers.d/ -p wa -k identity
If the command does not return a line or the line is commented out, this is a finding.
Note: The "-k" allows for specifying an arbitrary identifier, and the string after it does not need to match the example output above.
M
5664