Fix OpenRC status dir labeling for Gentoo
PATCH 1/2 Fix OpenRC status dir labeling for Gentoo
Current policy sets /lib(32|64)?/rc/init.d to lib_t. This causes problems for DHCP among other things, as the initrc domain does not have permissions to perform some operations. Changing to initrc_state_t (the labeling used for /var/lib/init.d by the older baselayout-1) resolves some of these issues.
Signed-off-by Chris Richards <[email protected]>
--- policy/modules/system/init.fc | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-)
policy/modules/system/init.fc +8 -0
@@ -66,3 +66,11 @@ ifdef(`distro_suse', ` /var/run/sysconfig(/.*)? gen_context(system_u:object_r:initrc_var_run_t,s0) ') +# +# /lib +# +ifdef(`distro_gentoo', ` +/lib/rc/init\.d(/.*)? gen_context(system_u:object_r:initrc_state_t,s0) +/lib32/rc/init\.d(/.*)? gen_context(system_u:object_r:initrc_state_t,s0) +/lib64/rc/init\.d(/.*)? gen_context(system_u:object_r:initrc_state_t,s0) +')
Signature · 1 line
1.7.3.2
PATCH 1/2 Fix OpenRC status dir labeling for Gentoo
Quoted 5 lines · Chris Richards
Current policy sets /lib(32|64)?/rc/init.d to
lib_t. This causes problems for DHCP among other things, as the initrc domain does not have permissions to perform some operations. Changing toinitrc_state_t(the labeling used for/var/lib/init.dby the older baselayout-1) resolves some of these issues.
This pair is merged.
Quoted 21 lines
Signed-off-by Chris Richards <[email protected]>--- policy/modules/system/init.fc | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-)policy/modules/system/init.fc +8
-0@@ -66,3 +66,11 @@ ifdef(`distro_suse', ` /var/run/sysconfig(/.*)? gen_context(system_u:object_r:initrc_var_run_t,s0) ') +# +# /lib +# +ifdef(`distro_gentoo', ` +/lib/rc/init\.d(/.*)? gen_context(system_u:object_r:initrc_state_t,s0) +/lib32/rc/init\.d(/.*)? gen_context(system_u:object_r:initrc_state_t,s0) +/lib64/rc/init\.d(/.*)? gen_context(system_u:object_r:initrc_state_t,s0) +')
Signature · 3 lines
Chris PeBenito Tresys Technology, LLC www.tresys.com | oss.tresys.com