public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [tests/selinux] pr775-checkpolicy-revdeps: setsebool: enable PATH records while running
@ 2026-09-11 13:17 Petr Lautrbach
  0 siblings, 0 replies; only message in thread
From: Petr Lautrbach @ 2026-09-11 13:17 UTC (permalink / raw)
  To: git-commits

            A new commit has been pushed.

            Repo   : tests/selinux
            Branch : pr775-checkpolicy-revdeps
            Commit : f98e16dc947e496de85fbde4a0220ae2547a6a7a
            Author : Petr Lautrbach <plautrba@redhat.com>
            Date   : 2020-01-10T10:03:31+01:00
            Stats  : +13/-3 in 2 file(s)
            URL    : https://src.fedoraproject.org/tests/selinux/c/f98e16dc947e496de85fbde4a0220ae2547a6a7a?branch=pr775-checkpolicy-revdeps

            Log:
            setsebool: enable PATH records while running

This test expects it's enabled

---
diff --git a/policycoreutils/load_policy/runtest.sh b/policycoreutils/load_policy/runtest.sh
index eaa5bac..f71e1e6 100755
--- a/policycoreutils/load_policy/runtest.sh
+++ b/policycoreutils/load_policy/runtest.sh
@@ -48,9 +48,9 @@ rlJournalStart
             sleep 1
         fi
         rlRun "AUDIT_FILE=$(mktemp)"
-	rlRun "auditctl -l | tee -a $AUDIT_FILE" 0 "Save current audit rules"
+        rlRun "auditctl -l | tee -a $AUDIT_FILE" 0 "Save current audit rules"
         rlRun "auditctl -D" 0
-	rlRun "auditctl -w $AUDIT_FILE -p w" 0 \
+        rlRun "auditctl -w $AUDIT_FILE -p w" 0 \
 	    "Enable creation of PATH audit records"
     rlPhaseEnd
 
@@ -94,7 +94,7 @@ rlJournalStart
     rlPhaseStartCleanup
         rlRun "auditctl -W $AUDIT_FILE -p w" 0 \
               "Remove rule for creation of PATH audit records"
-	rlRun "auditctl -R $AUDIT_FILE" 0 "Restore audit rules"
+        rlRun "auditctl -R $AUDIT_FILE" 0,1 "Restore audit rules"
         rlRun "rm -f \"\$AUDIT_FILE\""
     rlPhaseEnd
 rlJournalPrintText

diff --git a/policycoreutils/setsebool/runtest.sh b/policycoreutils/setsebool/runtest.sh
index 04040d1..202d641 100755
--- a/policycoreutils/setsebool/runtest.sh
+++ b/policycoreutils/setsebool/runtest.sh
@@ -48,6 +48,12 @@ rlJournalStart
 
         rlRun "useradd ${USER_NAME}"
         rlRun "echo ${USER_SECRET} | passwd --stdin ${USER_NAME}"
+        rlRun "AUDIT_FILE=$(mktemp)"
+        rlRun "auditctl -l | tee -a $AUDIT_FILE" 0 "Save current audit rules"
+        rlRun "auditctl -D" 0
+        rlRun "auditctl -w $AUDIT_FILE -p w" 0 \
+	    "Enable creation of PATH audit records"
+
     rlPhaseEnd
 
     rlPhaseStartTest
@@ -145,6 +151,10 @@ rlJournalStart
     rlPhaseStartCleanup
         rlRun "userdel -rf ${USER_NAME}"
         rm -f ${OUTPUT_FILE}
+        rlRun "auditctl -W $AUDIT_FILE -p w" 0 \
+              "Remove rule for creation of PATH audit records"
+        rlRun "auditctl -R $AUDIT_FILE" 0,1 "Restore audit rules"
+        rlRun "rm -f \"\$AUDIT_FILE\""
     rlPhaseEnd
 rlJournalPrintText
 rlJournalEnd

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2026-09-11 13:17 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-09-11 13:17 [tests/selinux] pr775-checkpolicy-revdeps: setsebool: enable PATH records while running Petr Lautrbach

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox