All of lore.kernel.org
 help / color / mirror / Atom feed
* [refpolicy] Potential discrepance of user's HOME when polyinstantiation is enabled
@ 2011-02-11  3:33 HarryCiao
  2011-02-16 14:03 ` Christopher J. PeBenito
  0 siblings, 1 reply; 2+ messages in thread
From: HarryCiao @ 2011-02-11  3:33 UTC (permalink / raw)
  To: refpolicy


Hi all,

On my sandbox if polyinstantiation is enabled then user's HOME will be created in /home/home.inst/ (the instance directory) and mounted to /home/[user] (the base directory). The namespace.conf is quoted below:


[root/sysadm_r/s0 at localhost ~]# cat /etc/security/namespace.conf

...

/tmp     /tmp-inst/             level     root,adm

/var/tmp /var/tmp-inst/         level     root,adm

$HOME    /home/home.inst/       level     root,adm

[root/sysadm_r/s0 at localhost ~]# 

 [root/sysadm_r/s0 at localhost ~]# matchpathcon /home/
/home   system_u:object_r:home_root_t:s0-s15:c0.c1023
[root/sysadm_r/s0 at localhost ~]# matchpathcon /home/home.inst
/home/home.inst system_u:object_r:tmp_t:s0
[root/sysadm_r/s0 at localhost ~]# matchpathcon /home/home.inst/something
/home/home.inst/something       user_u:object_r:user_home_t:s0
[root/sysadm_r/s0 at localhost ~]# 


As we can see, the instance directory will be labeled as user_home_t, rather than user_home_dir_t as the base directory.

Is this correct? if not, how could I properly define the label of the instance directory to be the same as that of the base directory?

If yes, then I am afraid applications would have to be granted the user_home_t:dir search permissions at least along with the search permission on user_home_dir_t. The attached patch contains an example for [user]_screen_t.

Thanks a lot!

Best regards,
Harry

 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://oss.tresys.com/pipermail/refpolicy/attachments/20110211/c5132dd6/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: refpolicy-strict-fix-userdom_user_home_domtrans.patch
Type: text/x-patch
Size: 1161 bytes
Desc: not available
Url : http://oss.tresys.com/pipermail/refpolicy/attachments/20110211/c5132dd6/attachment.bin 

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2011-02-16 14:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-11  3:33 [refpolicy] Potential discrepance of user's HOME when polyinstantiation is enabled HarryCiao
2011-02-16 14:03 ` Christopher J. PeBenito

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.