SV-269466r1050349_rule
V-269466
SRG-OS-000477-GPOS-00222
ALMA-09-046660
CAT II
10
Configure AlmaLinux OS 9 to generate an audit event for any successful/unsuccessful use of the "delete_module", "init_module" and "finit_module" system calls.
Add the following lines to the "/etc/audit/rules.d/audit.rules" file:
-a always,exit -F arch=b32 -S init_module,finit_module -F auid>=1000 -F auid!=unset -k module_chng
-a always,exit -F arch=b64 -S init_module,finit_module -F auid>=1000 -F auid!=unset -k module_chng
-a always,exit -F arch=b32 -S delete_module -F auid>=1000 -F auid!=unset -k module_chng
-a always,exit -F arch=b64 -S delete_module -F auid>=1000 -F auid!=unset -k module_chng
Merge the rules into /etc/audit/audit.rules:
$ augenrules --load
Verify that AlmaLinux OS 9 is configured to audit the execution of the "delete_module", "init_module" and "finit_module" system calls with the following command:
$ auditctl -l | grep module
-a always,exit -F arch=b32 -S init_module,finit_module -F auid>=1000 -F auid!=unset -k module_chng
-a always,exit -F arch=b64 -S init_module,finit_module -F auid>=1000 -F auid!=unset -k module_chng
-a always,exit -F arch=b32 -S delete_module -F auid>=1000 -F auid!=unset -k module_chng
-a always,exit -F arch=b64 -S delete_module -F auid>=1000 -F auid!=unset -k module_chng
If both the "b32" and "b64" audit rules are not defined for the "delete_module", "init_module" and "finit_module" system calls, or any of the lines returned are commented out, this is a finding.
V-269466
False
ALMA-09-046660
Verify that AlmaLinux OS 9 is configured to audit the execution of the "delete_module", "init_module" and "finit_module" system calls with the following command:
$ auditctl -l | grep module
-a always,exit -F arch=b32 -S init_module,finit_module -F auid>=1000 -F auid!=unset -k module_chng
-a always,exit -F arch=b64 -S init_module,finit_module -F auid>=1000 -F auid!=unset -k module_chng
-a always,exit -F arch=b32 -S delete_module -F auid>=1000 -F auid!=unset -k module_chng
-a always,exit -F arch=b64 -S delete_module -F auid>=1000 -F auid!=unset -k module_chng
If both the "b32" and "b64" audit rules are not defined for the "delete_module", "init_module" and "finit_module" system calls, or any of the lines returned are commented out, this is a finding.
M
5664