From: "Kenton Groombridge" <concord@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/hardened-refpolicy:master commit in: policy/modules/system/, policy/modules/kernel/, policy/modules/services/
Date: Fri, 31 Mar 2023 23:07:10 +0000 (UTC) [thread overview]
Message-ID: <1680282687.c26f03fa94aa2e08b219d5040970d21c1c26869c.concord@gentoo> (raw)
commit: c26f03fa94aa2e08b219d5040970d21c1c26869c
Author: Kenton Groombridge <me <AT> concord <DOT> sh>
AuthorDate: Mon Mar 6 15:14:55 2023 +0000
Commit: Kenton Groombridge <concord <AT> gentoo <DOT> org>
CommitDate: Fri Mar 31 17:11:27 2023 +0000
URL: https://gitweb.gentoo.org/proj/hardened-refpolicy.git/commit/?id=c26f03fa
various: make /etc/machine-id etc_runtime_t
This file is updated at boot by systemd.
Signed-off-by: Kenton Groombridge <me <AT> concord.sh>
Signed-off-by: Kenton Groombridge <concord <AT> gentoo.org>
policy/modules/kernel/files.fc | 1 +
policy/modules/services/dbus.te | 2 ++
policy/modules/system/systemd.te | 6 ++++++
3 files changed, 9 insertions(+)
diff --git a/policy/modules/kernel/files.fc b/policy/modules/kernel/files.fc
index b22d97997..708abd32e 100644
--- a/policy/modules/kernel/files.fc
+++ b/policy/modules/kernel/files.fc
@@ -53,6 +53,7 @@ ifdef(`distro_suse',`
/etc/ioctl\.save -- gen_context(system_u:object_r:etc_runtime_t,s0)
/etc/killpower -- gen_context(system_u:object_r:etc_runtime_t,s0)
/etc/localtime -l gen_context(system_u:object_r:etc_t,s0)
+/etc/machine-id -- gen_context(system_u:object_r:etc_runtime_t,s0)
/etc/mtab -- gen_context(system_u:object_r:etc_runtime_t,s0)
/etc/mtab~[0-9]* -- gen_context(system_u:object_r:etc_runtime_t,s0)
/etc/mtab\.tmp -- gen_context(system_u:object_r:etc_runtime_t,s0)
diff --git a/policy/modules/services/dbus.te b/policy/modules/services/dbus.te
index 29ada52aa..f6d502940 100644
--- a/policy/modules/services/dbus.te
+++ b/policy/modules/services/dbus.te
@@ -197,6 +197,8 @@ ifdef(`init_systemd', `
dev_rw_dri(system_dbusd_t)
dev_rw_input_dev(system_dbusd_t)
+ files_read_etc_runtime_files(system_dbusd_t)
+
# for /run/systemd/dynamic-uid/
init_list_runtime(system_dbusd_t)
init_read_runtime_symlinks(system_dbusd_t)
diff --git a/policy/modules/system/systemd.te b/policy/modules/system/systemd.te
index cf91547e2..db594e615 100644
--- a/policy/modules/system/systemd.te
+++ b/policy/modules/system/systemd.te
@@ -493,6 +493,7 @@ dev_write_sysfs_dirs(systemd_generator_t)
dev_read_urand(systemd_generator_t)
files_read_etc_files(systemd_generator_t)
+files_read_etc_runtime_files(systemd_generator_t)
files_search_runtime(systemd_generator_t)
files_list_boot(systemd_generator_t)
files_read_boot_files(systemd_generator_t)
@@ -857,6 +858,7 @@ dev_setattr_dri_dev(systemd_logind_t)
dev_setattr_generic_usb_dev(systemd_logind_t)
dev_setattr_input_dev(systemd_logind_t)
dev_setattr_kvm_dev(systemd_logind_t)
+files_read_etc_runtime_files(systemd_logind_t)
dev_setattr_sound_dev(systemd_logind_t)
dev_setattr_video_dev(systemd_logind_t)
@@ -1140,6 +1142,7 @@ dev_read_sysfs(systemd_networkd_t)
dev_write_kmsg(systemd_networkd_t)
files_read_etc_files(systemd_networkd_t)
+files_read_etc_runtime_files(systemd_networkd_t)
files_watch_runtime_dirs(systemd_networkd_t)
files_watch_root_dirs(systemd_networkd_t)
files_list_runtime(systemd_networkd_t)
@@ -1415,6 +1418,9 @@ dontaudit systemd_pcrphase_t self:capability net_admin;
dev_rw_tpm(systemd_pcrphase_t)
dev_write_kmsg(systemd_pcrphase_t)
+# read /etc/machine-id
+files_read_etc_runtime_files(systemd_pcrphase_t)
+
fs_read_efivarfs_files(systemd_pcrphase_t)
fs_getattr_cgroup(systemd_pcrphase_t)
fs_search_cgroup_dirs(systemd_pcrphase_t)
next reply other threads:[~2023-03-31 23:07 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-31 23:07 Kenton Groombridge [this message]
-- strict thread matches above, loose matches on Subject: below --
2022-09-03 19:54 [gentoo-commits] proj/hardened-refpolicy:master commit in: policy/modules/system/, policy/modules/kernel/, policy/modules/services/ Jason Zaman
2021-02-07 3:20 Jason Zaman
2020-10-13 3:02 Jason Zaman
2020-10-13 3:02 Jason Zaman
2019-07-13 7:01 Jason Zaman
2017-11-05 8:01 Jason Zaman
2017-03-30 17:06 Jason Zaman
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=1680282687.c26f03fa94aa2e08b219d5040970d21c1c26869c.concord@gentoo \
--to=concord@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.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