From: "Sven Vermeulen" <swift@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/hardened-refpolicy:bitcoin commit in: policy/modules/system/
Date: Tue, 11 Nov 2014 16:00:31 +0000 (UTC) [thread overview]
Message-ID: <1415721546.91b06086bea526e22411773d54c897ef06d85861.swift@gentoo> (raw)
commit: 91b06086bea526e22411773d54c897ef06d85861
Author: Sven Vermeulen <sven.vermeulen <AT> siphos <DOT> be>
AuthorDate: Tue Nov 11 15:58:55 2014 +0000
Commit: Sven Vermeulen <swift <AT> gentoo <DOT> org>
CommitDate: Tue Nov 11 15:59:06 2014 +0000
URL: http://sources.gentoo.org/gitweb/?p=proj/hardened-refpolicy.git;a=commit;h=91b06086
Add support for init_script_readable
---
policy/modules/system/init.if | 18 ++++++++++++++++++
policy/modules/system/init.te | 5 +++++
2 files changed, 23 insertions(+)
diff --git a/policy/modules/system/init.if b/policy/modules/system/init.if
index 2b7793a..7cdf3a8 100644
--- a/policy/modules/system/init.if
+++ b/policy/modules/system/init.if
@@ -1906,3 +1906,21 @@ interface(`init_relabelto_script_state',`
relabelto_files_pattern($1, initrc_state_t, initrc_state_t)
relabelto_dirs_pattern($1, initrc_state_t, initrc_state_t)
')
+
+#########################################
+## <summary>
+## Mark as a readable type for the initrc_t domain
+## </summary>
+## <param name="type">
+## <summary>
+## Type that initrc_t needs read access to
+## </summary>
+## </param>
+#
+interface(`init_script_readable_type',`
+ gen_require(`
+ attribute init_script_readable;
+ ')
+
+ typeattribute $1 init_script_readable;
+')
diff --git a/policy/modules/system/init.te b/policy/modules/system/init.te
index cd2b0e4..cd3d18d 100644
--- a/policy/modules/system/init.te
+++ b/policy/modules/system/init.te
@@ -935,12 +935,17 @@ optional_policy(`
')
ifdef(`distro_gentoo',`
+ # Attribute to assign to types that the initrc_t domain needs read access to
+ attribute init_script_readable;
+
#####################################
#
# Local initrc_t policy
#
allow initrc_t self:capability sys_admin;
+ read_files_pattern(initrc_t, init_script_readable, init_script_readable)
+
manage_dirs_pattern(initrc_t, initrc_var_run_t, initrc_var_run_t)
files_pid_filetrans(initrc_t, initrc_var_run_t, dir)
next reply other threads:[~2014-11-11 16:00 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-11 16:00 Sven Vermeulen [this message]
-- strict thread matches above, loose matches on Subject: below --
2014-11-11 16:09 [gentoo-commits] proj/hardened-refpolicy:bitcoin commit in: policy/modules/system/ Sven Vermeulen
2014-11-22 19:02 [gentoo-commits] proj/hardened-refpolicy:master " Sven Vermeulen
2014-11-23 14:06 ` [gentoo-commits] proj/hardened-refpolicy:bitcoin " Sven Vermeulen
2014-11-23 14:06 Sven Vermeulen
2014-11-23 14:06 Sven Vermeulen
2014-11-28 10:04 [gentoo-commits] proj/hardened-refpolicy:next " Sven Vermeulen
2014-11-23 14:06 ` [gentoo-commits] proj/hardened-refpolicy:bitcoin " Sven Vermeulen
2014-11-28 10:04 [gentoo-commits] proj/hardened-refpolicy:next " Sven Vermeulen
2014-11-23 14:06 ` [gentoo-commits] proj/hardened-refpolicy:bitcoin " Sven Vermeulen
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=1415721546.91b06086bea526e22411773d54c897ef06d85861.swift@gentoo \
--to=swift@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