Skip to content

Commit

Permalink
make audit-sample-rules into a diff-style tool
Browse files Browse the repository at this point in the history
Based on recent discussions, turn the test into a diff-like tool
the output of which is to be always reviewed by a human.

This is in contrast to the old (current) state which treats the
test as a regression test, assuming it is meant to normally 'pass'.

And that would make sense if we wanted to keep audit rule lists stored
in the content identical with auditd samples, but we (CaC/content)
do not want that.

Instead, the intention is to just alert about any differences, and let
the humans decide whether they are significant enough to update the
CaC/content audit rules, and how.

Signed-off-by: Jiri Jaburek <[email protected]>
  • Loading branch information
comps authored and mildas committed Oct 9, 2024
1 parent e8b299e commit e8b53fb
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 20 deletions.
12 changes: 0 additions & 12 deletions conf/waivers/20-long-term
Original file line number Diff line number Diff line change
Expand Up @@ -121,18 +121,6 @@
/per-rule/.*/set_nftables_table/.*
rhel == 9

# /static-checks
#
# new arch= on RHEL-9.5
# https://github.com/ComplianceAsCode/content/issues/12321
/static-checks/audit-sample-rules/audit_ospp_general.*
rhel == 9.5
# older issues with pkexec and grub2-set-bootflag, they seem to appear
# only with older audit-3.0.x
# https://github.com/ComplianceAsCode/content/issues/12321
/static-checks/audit-sample-rules/audit_ospp_general.*
(rhel == 9 and rhel <= 9.3) or rhel == 8.8

# RHEL10 - No official RHEL10 STIG/CIS benchmark yet
/static-checks/rule-identifiers/(stig|cis.*)/.*
rhel == 10
Expand Down
8 changes: 0 additions & 8 deletions static-checks/audit-sample-rules/main.fmf

This file was deleted.

File renamed without changes.
6 changes: 6 additions & 0 deletions static-checks/diff/main.fmf
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,9 @@ adjust:
/profile-variables:
summary: Diff datastreams, output profile variable refine differences
test: python3 -m lib.runtest ./profile-variables.py

/audit-sample-rules:
summary: Diff audit.rules between Content and installed auditd samples
test: python3 -m lib.runtest ./audit-sample-rules.py
require+:
- audit

0 comments on commit e8b53fb

Please sign in to comment.