public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Milos Malik <mmalik@redhat.com>
To: git-commits@fedoraproject.org
Subject: [tests/selinux] pr775-checkpolicy-revdeps: test if policy defines the anon_inode class
Date: Fri, 11 Sep 2026 13:20:52 GMT	[thread overview]
Message-ID: <178913285245.1.14737273277710102541.tests-selinux-0443a95a9b73@fedoraproject.org> (raw)

            A new commit has been pushed.

            Repo   : tests/selinux
            Branch : pr775-checkpolicy-revdeps
            Commit : 0443a95a9b73f49d82380e7f48e0645029cd1802
            Author : Milos Malik <mmalik@redhat.com>
            Date   : 2023-07-18T11:23:22+02:00
            Stats  : +11/-2 in 3 file(s)
            URL    : https://src.fedoraproject.org/tests/selinux/c/0443a95a9b73f49d82380e7f48e0645029cd1802?branch=pr775-checkpolicy-revdeps

            Log:
            test if policy defines the anon_inode class

The BZ which introduced the anon_inode class into SELinux policy
was missing an automated test coverage until now.

The TC covers BZ#1954145.

---
diff --git a/selinux-policy/anon_inode-and-similar/Makefile b/selinux-policy/anon_inode-and-similar/Makefile
index 0a053b2..416a2b6 100644
--- a/selinux-policy/anon_inode-and-similar/Makefile
+++ b/selinux-policy/anon_inode-and-similar/Makefile
@@ -62,6 +62,7 @@ $(METADATA): Makefile
 	@echo "Destructive:     no" >> $(METADATA)
 	@echo "Environment:     AVC_ERROR=+no_avc_check" >> $(METADATA)
 	@echo "Releases:        -RHEL4" >> $(METADATA)
+	@echo "Bug:             1954145" >> $(METADATA) # RHEL-9
 	@echo "Bug:             1974559" >> $(METADATA)
 	@echo "Bug:             2027660" >> $(METADATA) # RHEL-9
 	@echo "Bug:             2025714" >> $(METADATA) # Fedora 35

diff --git a/selinux-policy/anon_inode-and-similar/main.fmf b/selinux-policy/anon_inode-and-similar/main.fmf
index e9ed5d7..b40664b 100644
--- a/selinux-policy/anon_inode-and-similar/main.fmf
+++ b/selinux-policy/anon_inode-and-similar/main.fmf
@@ -25,8 +25,10 @@ tag:
   - NoRHEL5
   - NoRHEL6
   - NoRHEL7
+  - NoRHEL8
   - targeted
 link:
+  - verifies: https://bugzilla.redhat.com/show_bug.cgi?id=1954145
   - relates: https://bugzilla.redhat.com/show_bug.cgi?id=1974559
   - relates: https://bugzilla.redhat.com/show_bug.cgi?id=2027660
   - verifies: https://bugzilla.redhat.com/show_bug.cgi?id=2025714
@@ -34,7 +36,7 @@ link:
 adjust:
   - enabled: false
     when: distro == rhel-4, rhel-5, rhel-6, rhel-7, rhel-8
-    continue: false
+    because: the anon_inode class is not defined there
 extra-nitrate: TC#0612643
 extra-summary: /CoreOS/selinux-policy/Regression/anon_inode-and-similar
 extra-task: /CoreOS/selinux-policy/Regression/anon_inode-and-similar

diff --git a/selinux-policy/anon_inode-and-similar/runtest.sh b/selinux-policy/anon_inode-and-similar/runtest.sh
index d7ddd4f..a58a606 100755
--- a/selinux-policy/anon_inode-and-similar/runtest.sh
+++ b/selinux-policy/anon_inode-and-similar/runtest.sh
@@ -50,6 +50,12 @@ rlJournalStart
         sleep 2
     rlPhaseEnd
 
+    rlPhaseStartTest "bz#1954145"
+        rlRun "seinfo -c | grep anon_inode"
+        rlRun "seinfo -c anon_inode -x"
+        rlRun "sesearch -s domain -t domain -c anon_inode -A -ds -dt"
+    rlPhaseEnd
+
     rlPhaseStartTest "SELinux policy prevents userfaultfds bz1974559"
         rlRun "gcc -o reproducer reproducer.c"
         tst_Time="$(date '+%T')"
@@ -65,7 +71,7 @@ rlJournalStart
         rlSESearchRule "allow svirt_t svirt_t : anon_inode { map } [ ]"
         rlSESearchRule "allow virtd_t virtd_t : anon_inode { map } [ ]"
 
-        rlRun "fio --filename=/root/pokus --iodepth=16 --rw=write --ioengine=io_uring --bs=16k --size=2G --numjobs=30 --runtime=100s --group_reporting=1 --name=mytest"
+        rlRun "fio --filename=/root/pokus --iodepth=16 --rw=write --ioengine=io_uring --bs=16k --size=2G --numjobs=30 --runtime=100s --group_reporting=1 --name=mytest" 0-255
     rlPhaseEnd
 
     rlPhaseStartCleanup

                 reply	other threads:[~2026-09-11 13:20 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=178913285245.1.14737273277710102541.tests-selinux-0443a95a9b73@fedoraproject.org \
    --to=mmalik@redhat.com \
    --cc=git-commits@fedoraproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox