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 valkey service can manage RDMA sockets
Date: Fri, 11 Sep 2026 13:23:38 GMT [thread overview]
Message-ID: <178913301873.1.1138697494031593426.tests-selinux-a47e77204660@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : tests/selinux
Branch : pr775-checkpolicy-revdeps
Commit : a47e7720466068f760bf56d6faee29ad812c39e1
Author : Milos Malik <mmalik@redhat.com>
Date : 2026-03-26T18:04:17+01:00
Stats : +12/-1 in 3 file(s)
URL : https://src.fedoraproject.org/tests/selinux/c/a47e7720466068f760bf56d6faee29ad812c39e1?branch=pr775-checkpolicy-revdeps
Log:
test if valkey service can manage RDMA sockets
Recent valkey + selinux-policy testing revealed that SELinux prevents
the valkey-server processes from creating and manipulating of RDMA
sockets when the valkey-rdma package is installed. The TC reproduces
the situation.
In order to enable the functions brought by the valkey-rdma package,
I believe that SELinux policy should allow the access. The TC looks
for appropriate policy rules and file context patterns.
The TC covers RHEL-154814 and RHEL-161115.
---
diff --git a/selinux-policy/valkey-and-similar/Makefile b/selinux-policy/valkey-and-similar/Makefile
index 2e576bf..e194474 100644
--- a/selinux-policy/valkey-and-similar/Makefile
+++ b/selinux-policy/valkey-and-similar/Makefile
@@ -55,7 +55,7 @@ $(METADATA): Makefile
@echo "TestTime: 10m" >> $(METADATA)
@echo "RunFor: selinux-policy" >> $(METADATA)
@echo "RunFor: valkey" >> $(METADATA)
- @echo "Requires: audit libselinux libselinux-utils policycoreutils selinux-policy selinux-policy-targeted setools-console valkey /usr/sbin/service" >> $(METADATA)
+ @echo "Requires: audit libselinux libselinux-utils policycoreutils selinux-policy selinux-policy-targeted setools-console valkey /usr/sbin/service valkey-rdma" >> $(METADATA)
@echo "RhtsRequires: library(selinux-policy/common)" >> $(METADATA)
@echo "Priority: Normal" >> $(METADATA)
@echo "License: GPLv2" >> $(METADATA)
@@ -65,6 +65,8 @@ $(METADATA): Makefile
@echo "Releases: -RHEL4 -RHEL5 -RHEL6 -RHEL7 -RHEL8" >> $(METADATA)
@echo "Bug: RHEL-102631" >> $(METADATA) # RHEL-10
@echo "Bug: RHEL-108982" >> $(METADATA) # RHEL-9
+ @echo "Bug: RHEL-154814" >> $(METADATA) # RHEL-10
+ @echo "Bug: RHEL-161115" >> $(METADATA) # RHEL-9
rhts-lint $(METADATA)
diff --git a/selinux-policy/valkey-and-similar/main.fmf b/selinux-policy/valkey-and-similar/main.fmf
index af010b8..16ddad7 100644
--- a/selinux-policy/valkey-and-similar/main.fmf
+++ b/selinux-policy/valkey-and-similar/main.fmf
@@ -18,6 +18,7 @@ recommend:
- selinux-policy-targeted
- setools-console
- valkey
+ - valkey-rdma
- /usr/sbin/service
environment:
AVC_ERROR: +no_avc_check
@@ -27,6 +28,8 @@ tier: '3'
link:
- verifies: https://issues.redhat.com/browse/RHEL-102631
- verifies: https://issues.redhat.com/browse/RHEL-108982
+ - verifies: https://issues.redhat.com/browse/RHEL-154814
+ - verifies: https://issues.redhat.com/browse/RHEL-161115
tag:
- Tier3
- Tier3se
diff --git a/selinux-policy/valkey-and-similar/runtest.sh b/selinux-policy/valkey-and-similar/runtest.sh
index 4a356ed..8b2830d 100755
--- a/selinux-policy/valkey-and-similar/runtest.sh
+++ b/selinux-policy/valkey-and-similar/runtest.sh
@@ -66,6 +66,12 @@ rlJournalStart
rlSEMatchPathCon "/usr/lib/systemd/system/valkey.service" "redis_unit_file_t"
rlPhaseEnd
+ if rpm -q valkey-rdma >& /dev/null ; then
+ rlPhaseStartTest "RHEL-154814 + RHEL-161115"
+ rlSESearchRule "allow redis_t redis_t : netlink_rdma_socket { getattr create setopt bind } [ ]"
+ rlPhaseEnd
+ fi
+
if [ -f /usr/lib/systemd/system/${SERVICE_NAME}.service ] ; then
rlPhaseStartTest "real scenario -- ${SERVICE_NAME} service"
if ! rlSEDefined ${PROCESS_CONTEXT} ; then
reply other threads:[~2026-09-11 13:23 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=178913301873.1.1138697494031593426.tests-selinux-a47e77204660@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