SHA256
1
0
forked from cockpit/cockpit
cockpit/0001-selinux-allow-login-to-read-motd-file.patch

29 lines
696 B
Diff

From 7884908e248a5954380cdfdb97f168e9f988fa54 Mon Sep 17 00:00:00 2001
From: Ludwig Nussel <ludwig.nussel@suse.de>
Date: Fri, 6 Aug 2021 15:11:23 +0200
Subject: [PATCH] selinux: allow login to read motd file
---
selinux/cockpit.te | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/selinux/cockpit.te b/selinux/cockpit.te
index b9910165c..52fc5fe63 100644
--- a/selinux/cockpit.te
+++ b/selinux/cockpit.te
@@ -180,3 +180,11 @@ optional_policy(`
optional_policy(`
unconfined_domtrans(cockpit_session_t)
')
+
+# login may read motd file through pam
+optional_policy(`
+ gen_require(`
+ type local_login_t;
+ ')
+ cockpit_read_pid_files(local_login_t)
+')
--
2.26.2