commit: a898469019293cb90dc8d26a5560966ac6c42a50
Author: Yi Zhao <yi.zhao <AT> windriver <DOT> com>
AuthorDate: Wed Feb 5 07:46:27 2025 +0000
Commit: Jason Zaman <perfinion <AT> gentoo <DOT> org>
CommitDate: Sat Mar 8 23:01:08 2025 +0000
URL:
https://gitweb.gentoo.org/proj/hardened-refpolicy.git/commit/?id=a8984690
ntp: allow systemd-timesyncd to watch /run/systemd dir
Fixes:
avc: denied { watch } for pid=297 comm="systemd-timesyn"
path="/run/systemd" dev="tmpfs" ino=2 scontext=system_u:system_r:ntpd_t
tcontext=system_u:object_r:init_runtime_t tclass=dir permissive=0
Signed-off-by: Yi Zhao <yi.zhao <AT> windriver.com>
Signed-off-by: Jason Zaman <perfinion <AT> gentoo.org>
policy/modules/services/ntp.te | 1 +
1 file changed, 1 insertion(+)
diff --git a/policy/modules/services/ntp.te b/policy/modules/services/ntp.te
index 72ef1067e..65d2fc396 100644
--- a/policy/modules/services/ntp.te
+++ b/policy/modules/services/ntp.te
@@ -159,6 +159,7 @@ ifdef(`init_systemd',`
allow ntpd_t self:capability { fowner setpcap };
init_read_state(ntpd_t)
init_reload(ntpd_t)
+ init_watch_runtime_dirs(ntpd_t)
fs_watch_memory_pressure(ntpd_t)
# for /var/lib/systemd/clock