From: "Sven Vermeulen" <sven.vermeulen@siphos.be>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/hardened-refpolicy:master commit in: policy/modules/contrib/
Date: Mon, 23 Sep 2013 13:31:41 +0000 (UTC) [thread overview]
Message-ID: <1379917639.d8ad674f9b897235cd243b9a37543bcfedb71d6e.SwifT@gentoo> (raw)
Message-ID: <20130923133141.X9jPbY1ffepjKcSNiJr2860lbH9sSjZ5MUskxsGaXFQ@z> (raw)
commit: d8ad674f9b897235cd243b9a37543bcfedb71d6e
Author: Dominick Grift <dominick.grift <AT> gmail <DOT> com>
AuthorDate: Thu Sep 19 17:39:39 2013 +0000
Commit: Sven Vermeulen <sven.vermeulen <AT> siphos <DOT> be>
CommitDate: Mon Sep 23 06:27:19 2013 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/hardened-refpolicy.git;a=commit;h=d8ad674f
Clean up libstoragemngmt policy module We do not yet support systemd
Signed-off-by: Dominick Grift <dominick.grift <AT> gmail.com>
---
policy/modules/contrib/lsm.fc | 4 +--
policy/modules/contrib/lsm.if | 79 ++-----------------------------------------
policy/modules/contrib/lsm.te | 9 ++---
3 files changed, 7 insertions(+), 85 deletions(-)
diff --git a/policy/modules/contrib/lsm.fc b/policy/modules/contrib/lsm.fc
index 711c04b..51777c1 100644
--- a/policy/modules/contrib/lsm.fc
+++ b/policy/modules/contrib/lsm.fc
@@ -1,5 +1,3 @@
-/usr/bin/lsmd -- gen_context(system_u:object_r:lsmd_exec_t,s0)
-
-/usr/lib/systemd/system/libstoragemgmt.* -- gen_context(system_u:object_r:lsmd_unit_file_t,s0)
+/usr/bin/lsmd -- gen_context(system_u:object_r:lsmd_exec_t,s0)
/var/run/lsm(/.*)? -- gen_context(system_u:object_r:lsmd_var_run_t,s0)
diff --git a/policy/modules/contrib/lsm.if b/policy/modules/contrib/lsm.if
index f3e94d7..d314333 100644
--- a/policy/modules/contrib/lsm.if
+++ b/policy/modules/contrib/lsm.if
@@ -1,72 +1,9 @@
-
-## <summary>lsmd SELINUX policy </summary>
-
-########################################
-## <summary>
-## Execute TEMPLATE in the lsmd domin.
-## </summary>
-## <param name="domain">
-## <summary>
-## Domain allowed to transition.
-## </summary>
-## </param>
-#
-interface(`lsmd_domtrans',`
- gen_require(`
- type lsmd_t, lsmd_exec_t;
- ')
-
- corecmd_search_bin($1)
- domtrans_pattern($1, lsmd_exec_t, lsmd_t)
-')
-########################################
-## <summary>
-## Read lsmd PID files.
-## </summary>
-## <param name="domain">
-## <summary>
-## Domain allowed access.
-## </summary>
-## </param>
-#
-interface(`lsmd_read_pid_files',`
- gen_require(`
- type lsmd_var_run_t;
- ')
-
- files_search_pids($1)
- read_files_pattern($1, lsmd_var_run_t, lsmd_var_run_t)
-')
-
-########################################
-## <summary>
-## Execute lsmd server in the lsmd domain.
-## </summary>
-## <param name="domain">
-## <summary>
-## Domain allowed to transition.
-## </summary>
-## </param>
-#
-interface(`lsmd_systemctl',`
- gen_require(`
- type lsmd_t;
- type lsmd_unit_file_t;
- ')
-
- systemd_exec_systemctl($1)
- systemd_read_fifo_file_password_run($1)
- allow $1 lsmd_unit_file_t:file read_file_perms;
- allow $1 lsmd_unit_file_t:service manage_service_perms;
-
- ps_process_pattern($1, lsmd_t)
-')
-
+## <summary>Storage array management library.</summary>
########################################
## <summary>
## All of the rules required to administrate
-## an lsmd environment
+## an lsmd environment.
## </summary>
## <param name="domain">
## <summary>
@@ -82,9 +19,7 @@ interface(`lsmd_systemctl',`
#
interface(`lsmd_admin',`
gen_require(`
- type lsmd_t;
- type lsmd_var_run_t;
- type lsmd_unit_file_t;
+ type lsmd_t, type lsmd_var_run_t;
')
allow $1 lsmd_t:process { ptrace signal_perms };
@@ -92,12 +27,4 @@ interface(`lsmd_admin',`
files_search_pids($1)
admin_pattern($1, lsmd_var_run_t)
-
- lsmd_systemctl($1)
- admin_pattern($1, lsmd_unit_file_t)
- allow $1 lsmd_unit_file_t:service all_service_perms;
- optional_policy(`
- systemd_passwd_agent_exec($1)
- systemd_read_fifo_file_passwd_run($1)
- ')
')
diff --git a/policy/modules/contrib/lsm.te b/policy/modules/contrib/lsm.te
index 14fe4d7..7f0ca47 100644
--- a/policy/modules/contrib/lsm.te
+++ b/policy/modules/contrib/lsm.te
@@ -12,15 +12,12 @@ init_daemon_domain(lsmd_t, lsmd_exec_t)
type lsmd_var_run_t;
files_pid_file(lsmd_var_run_t)
-type lsmd_unit_file_t;
-systemd_unit_file(lsmd_unit_file_t)
-
########################################
#
-# lsmd local policy
+# Local policy
#
-allow lsmd_t self:capability { setgid };
-allow lsmd_t self:process { fork };
+
+allow lsmd_t self:capability setgid;
allow lsmd_t self:unix_stream_socket create_stream_socket_perms;
manage_dirs_pattern(lsmd_t, lsmd_var_run_t, lsmd_var_run_t)
next reply other threads:[~2013-09-23 13:31 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-23 6:29 Sven Vermeulen [this message]
2013-09-23 13:31 ` [gentoo-commits] proj/hardened-refpolicy:master commit in: policy/modules/contrib/ Sven Vermeulen
-- strict thread matches above, loose matches on Subject: below --
2013-09-23 13:31 Sven Vermeulen
2013-09-23 6:29 ` [gentoo-commits] proj/hardened-refpolicy:merge " Sven Vermeulen
2013-09-23 13:31 [gentoo-commits] proj/hardened-refpolicy:master " Sven Vermeulen
2013-09-23 6:29 ` [gentoo-commits] proj/hardened-refpolicy:merge " Sven Vermeulen
2013-09-23 13:31 [gentoo-commits] proj/hardened-refpolicy:master " Sven Vermeulen
2013-09-23 6:29 ` [gentoo-commits] proj/hardened-refpolicy:merge " Sven Vermeulen
2013-09-23 13:31 [gentoo-commits] proj/hardened-refpolicy:master " Sven Vermeulen
2013-09-23 6:29 ` [gentoo-commits] proj/hardened-refpolicy:merge " Sven Vermeulen
2013-09-23 13:31 [gentoo-commits] proj/hardened-refpolicy:master " Sven Vermeulen
2013-09-23 6:29 ` [gentoo-commits] proj/hardened-refpolicy:merge " Sven Vermeulen
2013-09-23 13:31 [gentoo-commits] proj/hardened-refpolicy:master " Sven Vermeulen
2013-09-23 6:29 ` [gentoo-commits] proj/hardened-refpolicy:merge " Sven Vermeulen
2013-09-23 13:31 [gentoo-commits] proj/hardened-refpolicy:master " Sven Vermeulen
2013-09-23 6:29 ` [gentoo-commits] proj/hardened-refpolicy:merge " Sven Vermeulen
2013-09-23 13:31 [gentoo-commits] proj/hardened-refpolicy:master " Sven Vermeulen
2013-09-23 6:29 ` [gentoo-commits] proj/hardened-refpolicy:merge " Sven Vermeulen
2013-09-23 13:31 [gentoo-commits] proj/hardened-refpolicy:master " Sven Vermeulen
2013-09-23 6:29 ` [gentoo-commits] proj/hardened-refpolicy:merge " Sven Vermeulen
2013-09-23 6:29 Sven Vermeulen
2013-09-23 6:29 Sven Vermeulen
2013-09-23 6:29 Sven Vermeulen
2013-09-23 6:29 Sven Vermeulen
2013-09-23 6:29 Sven Vermeulen
2013-09-23 6:29 Sven Vermeulen
2013-09-23 6:29 Sven Vermeulen
2013-09-23 6:29 Sven Vermeulen
2013-09-23 6:29 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=1379917639.d8ad674f9b897235cd243b9a37543bcfedb71d6e.SwifT@gentoo \
--to=sven.vermeulen@siphos.be \
--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