unconfined_t and user_home_dir_type
Currently we have the attributes user_home_dir_type and user_home_type applied to the main types for the home directory of regular users in a strict policy configuration (this means user_t etc).
While it is possible to have unconfined_t and user_t on the same system, I don't expect this to be a common configuration. In fact I expect that in practice they will be mutually exclusive.
Therefore when unconfined_t is used it will be desired that they can do all normal things, such as having a POP server read mail from their ~/Maildir. Allowing such access would mean adding user_home_dir_type and user_home_type attributes to unconfined_home_dir_t and unconfined_home_t respectively.
Is there any reason for not doing this?
Signature · 9 lines
[email protected] http://etbe.coker.com.au/ My Blog http://www.coker.com.au/sponsorship.html Sponsoring Free Software development -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 7 lines · Russell Coker
Currently we have the attributes
user_home_dir_typeanduser_home_typeapplied to the main types for the home directory of regular users in a strict policy configuration (this meansuser_tetc).While it is possible to have
unconfined_tanduser_ton the same system, I don't expect this to be a common configuration. In fact I expect that in practice they will be mutually exclusive.
Actually, it is a common situation in modern Fedora - they can map users they wish to confine to user_u (and thus to user_t) while leaving e.g. root as unconfined_u and thus unconfined_t.
Quoted 8 lines
Therefore when
unconfined_tis used it will be desired that they can do all normal things, such as having a POP server read mail from their ~/Maildir. Allowing such access would mean addinguser_home_dir_typeanduser_home_typeattributes tounconfined_home_dir_tandunconfined_home_trespectively.Is there any reason for not doing this?
Signature · 8 lines
Stephen Smalley National Security Agency -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 5 lines · Stephen Smalley
Quoted 4 lines · Russell Coker
Currently we have the attributes
user_home_dir_typeanduser_home_typeapplied to the main types for the home directory of regular users in a strict policy configuration (this meansuser_tetc).
Quoted 7 lines
Quoted 3 lines
While it is possible to have
unconfined_tanduser_ton the same system, I don't expect this to be a common configuration. In fact I expect that in practice they will be mutually exclusive.Actually, it is a common situation in modern Fedora - they can map users they wish to confine to
user_u(and thus touser_t) while leaving e.g. root asunconfined_uand thusunconfined_t.
So what do they do for the "targeted" case where all users are unconfined_t and they want to have POP/IMAP servers retrieve mail from the users' home directories?
Signature · 10 lines
[email protected] http://etbe.coker.com.au/ My Blog http://www.coker.com.au/sponsorship.html Sponsoring Free Software development -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 10 lines · Russell Coker
Quoted 9 lines · Stephen Smalley
Quoted 7 lines · Russell Coker
Currently we have the attributes
user_home_dir_typeanduser_home_typeapplied to the main types for the home directory of regular users in a strict policy configuration (this meansuser_tetc).While it is possible to have
unconfined_tanduser_ton the same system, I don't expect this to be a common configuration. In fact I expect that in practice they will be mutually exclusive.
Quoted 7 lines
Quoted 3 lines
Actually, it is a common situation in modern Fedora - they can map users they wish to confine to
user_u(and thus touser_t) while leaving e.g. root asunconfined_uand thusunconfined_t.So what do they do for the "targeted" case where all users are
unconfined_tand they want to have POP/IMAP servers retrieve mail from the users' home directories?
Dan has no MAC-based home directory separations. All home dirs are user_home_dir_t in the Fedora policy.
Signature · 7 lines
Chris PeBenito <[email protected]> Developer, Hardened Gentoo Linux Public Key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0xE6AF9243 Key fingerprint = B0E6 877A 883F A57A 8E6A CB00 BC8E E42D E6AF 9243
Quoted 8 lines · Chris PeBenito
Quoted 8 lines
Quoted 7 lines
Quoted 3 lines
While it is possible to have
unconfined_tanduser_ton the same system, I don't expect this to be a common configuration. In fact I expect that in practice they will be mutually exclusive.Actually, it is a common situation in modern Fedora - they can map users they wish to confine to
user_u(and thus touser_t) while leaving e.g. root asunconfined_uand thusunconfined_t.
Quoted 6 lines
Quoted 3 lines
So what do they do for the "targeted" case where all users are
unconfined_tand they want to have POP/IMAP servers retrieve mail from the users' home directories?Dan has no MAC-based home directory separations. All home dirs are
user_home_dir_tin the Fedora policy.
1) In a default configuration we want to have the users be unconfined (otherwise they complain too much.
2) For full functionality we need to have daemons such as a POP server, a mail server (or it's local delivery agent), and a web server access the home directories of all regular users.
3) Allowing daemons to mess with super-powerful domains is of course a bad idea, which is why we never let daemons access sysadm_home_dir_t. But preventing them from messing with ~/.bashrc etc while fulfilling the above two conditions and making the system easy to use is almost impossible (maybe restorecond has some potential to alleviate this, but it's still going to be hard).
So we can have a boolean to allow the compromise for item 3 and have it enabled by default. So by default users get domain unconfined_t, home directory label unconfined_home_dir_t, and the POP server etc can access that.
To improve security we need to prevent the daemons messing with users who are unconfined_t, that means unsetting the boolean in question and giving domain user_t to users who have full interaction with daemons.
The next step up after that is to assign root the roles staff_r and sysadm_r and remove unconfined.pp.
Am I missing anything?
Signature · 9 lines
[email protected] http://etbe.coker.com.au/ My Blog http://www.coker.com.au/sponsorship.html Sponsoring Free Software development -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.
Quoted 35 lines · Russell Coker
Quoted 8 lines · Chris PeBenito
Quoted 8 lines
Quoted 7 lines
Quoted 3 lines
While it is possible to have
unconfined_tanduser_ton the same system, I don't expect this to be a common configuration. In fact I expect that in practice they will be mutually exclusive.Actually, it is a common situation in modern Fedora - they can map users they wish to confine to
user_u(and thus touser_t) while leaving e.g. root asunconfined_uand thusunconfined_t.Quoted 6 lines
Quoted 3 lines
So what do they do for the "targeted" case where all users are
unconfined_tand they want to have POP/IMAP servers retrieve mail from the users' home directories?Dan has no MAC-based home directory separations. All home dirs are
user_home_dir_tin the Fedora policy.1) In a default configuration we want to have the users be unconfined (otherwise they complain too much.
2) For full functionality we need to have daemons such as a POP server, a mail server (or it's local delivery agent), and a web server access the home directories of all regular users.
3) Allowing daemons to mess with super-powerful domains is of course a bad idea, which is why we never let daemons access
sysadm_home_dir_t. But preventing them from messing with ~/.bashrc etc while fulfilling the above two conditions and making the system easy to use is almost impossible (maybe restorecond has some potential to alleviate this, but it's still going to be hard).So we can have a boolean to allow the compromise for item 3 and have it enabled by default. So by default users get domain
unconfined_t, home directory labelunconfined_home_dir_t, and the POP server etc can access that.
Quoted 8 lines
To improve security we need to prevent the daemons messing with users who are
unconfined_t, that means unsetting the boolean in question and giving domainuser_tto users who have full interaction with daemons.The next step up after that is to assign root the roles
staff_randsysadm_rand remove unconfined.pp.Am I missing anything?
Sounds about right. It boils down to: we want to treat unconfined_r like an unprivileged role for functionality reasons, but want to protect it for security reasons. A tunable is the best solution for allowing the user to set which of the two above options is preferred.
Signature · 9 lines
Chris PeBenito Tresys Technology, LLC (410) 290-1411 x150 -- This message was distributed to subscribers of the selinux mailing list. If you no longer wish to subscribe, send mail to [email protected] with the words "unsubscribe selinux" without quotes as the message.