public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [tests/selinux] pr775-checkpolicy-revdeps: test the lockdown class only if it defined
@ 2026-09-11 13:19 Milos Malik
  0 siblings, 0 replies; only message in thread
From: Milos Malik @ 2026-09-11 13:19 UTC (permalink / raw)
  To: git-commits

            A new commit has been pushed.

            Repo   : tests/selinux
            Branch : pr775-checkpolicy-revdeps
            Commit : 7323ae1899ffee8699fd2949758ef92837457f7f
            Author : Milos Malik <mmalik@redhat.com>
            Date   : 2022-02-03T14:35:12+01:00
            Stats  : +2/-2 in 2 file(s)
            URL    : https://src.fedoraproject.org/tests/selinux/c/7323ae1899ffee8699fd2949758ef92837457f7f?branch=pr775-checkpolicy-revdeps

            Log:
            test the lockdown class only if it defined

The lockdown class was removed from SELinux policy in BZ#2017848.
There are test phases in various automated tests which look for
policy rules related to the lockdown class. These tests were failing.
From now on, they should not fail because the problematic test phases
are skipped.

---
diff --git a/selinux-policy/lockdown-class/runtest.sh b/selinux-policy/lockdown-class/runtest.sh
index c008272..9bed740 100755
--- a/selinux-policy/lockdown-class/runtest.sh
+++ b/selinux-policy/lockdown-class/runtest.sh
@@ -33,7 +33,7 @@
 PACKAGE="selinux-policy"
 
 rlJournalStart
-    if rlIsRHEL '<9' ; then
+    if ! seinfo -c | grep -q lockdown ; then
         rlLog "Not applicable to this OS version."
         rlJournalEnd
         exit 0

diff --git a/selinux-policy/systemd-modules-load-and-similar/runtest.sh b/selinux-policy/systemd-modules-load-and-similar/runtest.sh
index 2f69ac8..d62bd6f 100755
--- a/selinux-policy/systemd-modules-load-and-similar/runtest.sh
+++ b/selinux-policy/systemd-modules-load-and-similar/runtest.sh
@@ -126,7 +126,7 @@ rlJournalStart
         rlRun "lsmod | grep rdma"
         rlRun "ausearch -m AVC -m USER_AVC --start $tst_Time" 1
         rlRun "systemctl stop rdma-load-modules@rdma.service"
-        if ! rlIsRHEL 8 ; then
+        if seinfo -c | grep -q lockdown ; then
             rlSESearchRule "allow systemd_modules_load_t systemd_modules_load_t : lockdown { confidentiality } [ ]"
         fi
     rlPhaseEnd

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

only message in thread, other threads:[~2026-09-11 13:19 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:19 [tests/selinux] pr775-checkpolicy-revdeps: test the lockdown class only if it defined Milos Malik

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