func/core/pkg_auditd/11-generate-events.sh
2024-08-14 20:52:26 -07:00

13 lines
354 B
Bash
Executable File

#!/bin/bash
r_log "auditd" "Generate events for audit log"
r_log "auditd" "Add test user"
useradd relengauditd
grep "ADD_USER" /var/log/audit/audit.log | grep -q 'acct="relengauditd"'
r_checkExitStatus $?
r_log "auditd" "Delete test user"
userdel relengauditd
grep "DEL_USER" /var/log/audit/audit.log | grep -q 'ID="relengauditd"'
r_checkExitStatus $?