From: cpebenito@tresys.com (Christopher J. PeBenito)
To: refpolicy@oss.tresys.com
Subject: [refpolicy] [PATCH v2 1/7] Label systemd files in init module
Date: Fri, 12 Sep 2014 11:31:47 -0400 [thread overview]
Message-ID: <541311E3.2020608@tresys.com> (raw)
In-Reply-To: <1410125296-26728-1-git-send-email-nicolas.iooss@m4x.org>
On 9/7/2014 5:28 PM, Nicolas Iooss wrote:
> ---
> policy/modules/system/init.fc | 6 ++++++
> policy/modules/system/init.te | 8 +++++++-
> 2 files changed, 13 insertions(+), 1 deletion(-)
This set is merged, though I made a few slight tweaks.
> diff --git a/policy/modules/system/init.fc b/policy/modules/system/init.fc
> index bc0ffc84ed07..417d3580b3a7 100644
> --- a/policy/modules/system/init.fc
> +++ b/policy/modules/system/init.fc
> @@ -25,6 +25,7 @@ ifdef(`distro_gentoo',`
> ifdef(`distro_gentoo', `
> /lib/rc/init\.d(/.*)? gen_context(system_u:object_r:initrc_state_t,s0)
> ')
> +/lib/systemd/systemd -- gen_context(system_u:object_r:init_exec_t,s0)
>
> #
> # /sbin
> @@ -42,6 +43,8 @@ ifdef(`distro_gentoo', `
> #
> /usr/bin/sepg_ctl -- gen_context(system_u:object_r:initrc_exec_t,s0)
>
> +/usr/lib/systemd/systemd -- gen_context(system_u:object_r:init_exec_t,s0)
> +
> /usr/libexec/dcc/start-.* -- gen_context(system_u:object_r:initrc_exec_t,s0)
> /usr/libexec/dcc/stop-.* -- gen_context(system_u:object_r:initrc_exec_t,s0)
>
> @@ -51,11 +54,14 @@ ifdef(`distro_gentoo', `
> #
> # /var
> #
> +/var/lib/systemd(/.*)? gen_context(system_u:object_r:init_var_lib_t,s0)
> +
> /var/run/initctl -p gen_context(system_u:object_r:initctl_t,s0)
> /var/run/utmp -- gen_context(system_u:object_r:initrc_var_run_t,s0)
> /var/run/runlevel\.dir gen_context(system_u:object_r:initrc_var_run_t,s0)
> /var/run/random-seed -- gen_context(system_u:object_r:initrc_var_run_t,s0)
> /var/run/setmixer_flag -- gen_context(system_u:object_r:initrc_var_run_t,s0)
> +/var/run/systemd(/.*)? gen_context(system_u:object_r:init_var_run_t,s0)
>
> ifdef(`distro_debian',`
> /var/run/hotkey-setup -- gen_context(system_u:object_r:initrc_var_run_t,s0)
> diff --git a/policy/modules/system/init.te b/policy/modules/system/init.te
> index 29256b862a64..b57637504939 100644
> --- a/policy/modules/system/init.te
> +++ b/policy/modules/system/init.te
> @@ -40,12 +40,18 @@ kernel_domtrans_to(init_t, init_exec_t)
> role system_r types init_t;
>
> #
> -# init_var_run_t is the type for /var/run/shutdown.pid.
> +# init_var_run_t is the type for /var/run/shutdown.pid and /var/run/systemd.
> #
> type init_var_run_t;
> files_pid_file(init_var_run_t)
>
> #
> +# init_var_lib_t is the type for /var/lib/systemd.
> +#
> +type init_var_lib_t;
> +files_type(init_var_lib_t)
> +
> +#
> # initctl_t is the type of the named pipe created
> # by init during initialization. This pipe is used
> # to communicate with init.
>
--
Chris PeBenito
Tresys Technology, LLC
www.tresys.com | oss.tresys.com
prev parent reply other threads:[~2014-09-12 15:31 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-07 21:28 [refpolicy] [PATCH v2 1/7] Label systemd files in init module Nicolas Iooss
2014-09-07 21:28 ` [refpolicy] [PATCH v2 2/7] Introduce init_search_run interface Nicolas Iooss
2014-09-07 21:28 ` [refpolicy] [PATCH v2 3/7] Label systemd-journald files and directories Nicolas Iooss
2014-09-07 21:28 ` [refpolicy] [PATCH v2 4/7] Support logging with /run/systemd/journal/dev-log Nicolas Iooss
2014-09-07 21:28 ` [refpolicy] [PATCH v2 5/7] Allow journald to read the kernel ring buffer and to use /dev/kmsg Nicolas Iooss
2014-09-07 21:28 ` [refpolicy] [PATCH v2 6/7] Allow journald to access to the state of all processes Nicolas Iooss
2014-09-07 21:28 ` [refpolicy] [PATCH v2 7/7] Remove redundant Gentoo-specific term_append_unallocated_ttys(syslogd_t) Nicolas Iooss
2014-09-12 15:31 ` Christopher J. PeBenito [this message]
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=541311E3.2020608@tresys.com \
--to=cpebenito@tresys.com \
--cc=refpolicy@oss.tresys.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.