Skip to contentSkip to conversation

purpose of the staff_r role?

DISCUSSION Tom Anderson 6 participants 10 messages Sep 30, 2004 – Oct 3, 2004 SELinux security module

lore
Share & tools
lore
#0 lore raw

Can anyone explain the purpose/benefit of having an account under the staff_r role? I thought it was to allow limited administrative functions, but I've discovered that it doesn't even allow reading the logfiles under /var/log/. What purpose does it serve, other than to limit who can transition to sysadm_r?

SE Linux appears to be quite powerful, but dear $deity it's confusing. I'd sell my soul for a nice, readable O'Reilly Press title covering this stuff!

__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - 100MB free storage!
http://promotions.yahoo.com/new_mail

--
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.

#1 lore raw

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Howdy,

Quoted 1 line · Tom Anderson

SE Linux appears to be quite powerful, but dear $deity it's confusing.

- From one new SELinux user to another, keep tinkering around with it, it'll start to make sense :-) You're right, it is really powerful. Don't be afraid to get in there and work with the policies (just make a backup, RCS is your friend ;-)

Nothing will help you figure it out quicker than building a policy for a daemon without one :-)

Quoted 2 lines

I'd sell my soul for a nice, readable O'Reilly Press title covering this stuff!

Well, lucky for you, you might not need to go quite that far ;-)

It looks like O'Reilly will be releasing one named "SELinux NSA's Open Source Security Enhanced Linux" by Bill McCarty pretty soon:

http://www.oreilly.com/catalog/selinux/index.html

The estimated release date is October. I'm looking forward to that myself.

Good luck!
-Eric

- --

 Eric Andreychek              | Lucy: "What happens if you practice the
 Eric Conspiracy Secret Labs  |  piano for 20 years and then end up not
 [email protected]         |  being rich and famous?"
 http://openthought.net       | Schroeder: "The joy is in the playing."

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFBW4b8R5UKaDAjAG4RAhRhAKDgM8GT9BZxRFcHqcBMk7/QMRENyACcDFbu cys8mXtVF8yKvu8VuH0MXJA=
=2hWg
-----END PGP SIGNATURE-----

--
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.

#2 lore raw
In reply to Tom Anderson
Quoted 9 lines · Tom Anderson

Can anyone explain the purpose/benefit of having an account under the staff_r role? I thought it was to allow limited administrative functions, but I've discovered that it doesn't even allow reading the logfiles under /var/log/. What purpose does it serve, other than to limit who can transition to sysadm_r?

SE Linux appears to be quite powerful, but dear $deity it's confusing. I'd sell my soul for a nice, readable O'Reilly Press title covering this stuff!

There is one in the works. I saw a draft copy at LinuxWorld in San Francisco early August. The title is "SELINUX: NSA's Open Source Security Enhanced Linux" and the author is Bill McCarty.

Now, do I get your soul or does O'Reilly?

--
Rolling Horse Ranch Technical Services Carsten P. Gehrke
Custom software solutions using open source technology
http://tech.RollingHorse.com/ [email protected]

--
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.

#3 lore raw
In reply to Tom Anderson
Quoted 5 lines · Tom Anderson

Can anyone explain the purpose/benefit of having an account under the staff_r role? I thought it was to allow limited administrative functions, but I've discovered that it doesn't even allow reading the logfiles under /var/log/. What purpose does it serve, other than to limit who can transition to sysadm_r?

It's the role that a person who can become sysadm_r should do their daily work in like reading mail, working on source code, etc. The reason is because it basically isn't allowed to interact with user_t at all; for example, staff_t can't read user_tmp_t. This prevents /tmp races from working.

--
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.

#4 lore raw
Quoted 5 lines

It's the role that a person who can become sysadm_r should do their daily work in like reading mail, working on source code, etc. The reason is because it basically isn't allowed to interact with user_t at all; for example, staff_t can't read user_tmp_t. This prevents /tmp races from working.

Ah, that makes sense. But I'd like my staff_t user able to read logfiles, without needing to become sysadm_r first ('cuz I can do some real damage inadvertently). Is there a "correct" way to do this? I've tried granting read access to var_log_t, but several daemons have their own logfile types.

_______________________________
Do you Yahoo!?
Express yourself with Y! Messenger! Free. Download now.
http://messenger.yahoo.com

--
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.

#5 lore raw
Quoted 11 lines · Tom Anderson
Quoted 5 lines

It's the role that a person who can become sysadm_r should do their daily work in like reading mail, working on source code, etc. The reason is because it basically isn't allowed to interact with user_t at all; for example, staff_t can't read user_tmp_t. This prevents /tmp races from working.

Ah, that makes sense. But I'd like my staff_t user able to read logfiles, without needing to become sysadm_r first ('cuz I can do some real damage inadvertently). Is there a "correct" way to do this? I've tried granting read access to var_log_t, but several daemons have their own logfile types.

r_dir_file(staff_t, logfile)

Signature · 9 lines
http://www.coker.com.au/selinux/   My NSA Security Enhanced Linux packages
http://www.coker.com.au/bonnie++/  Bonnie++ hard drive benchmark
http://www.coker.com.au/postal/    Postal SMTP/POP benchmark
http://www.coker.com.au/~russell/  My home page

--
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.
#6 lore raw
Quoted 1 line · --- Russell Coker

r_dir_file(staff_t, logfile)

Thank you. Is there a similar trick for seeing the full process information under ps? I see there's a "can_ps" macro, but so far I haven't managed to get the arguments right.

_______________________________
Do you Yahoo!?
Declare Yourself - Register online to vote today!
http://vote.yahoo.com

--
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.

#7 lore raw
Quoted 6 lines · Tom Anderson
Quoted 1 line · --- Russell Coker

r_dir_file(staff_t, logfile)

Thank you. Is there a similar trick for seeing the full process information under ps? I see there's a "can_ps" macro, but so far I haven't managed to get the arguments right.

can_ps(staff_t, domain) probably does what you want.

Signature · 9 lines
http://www.coker.com.au/selinux/   My NSA Security Enhanced Linux packages
http://www.coker.com.au/bonnie++/  Bonnie++ hard drive benchmark
http://www.coker.com.au/postal/    Postal SMTP/POP benchmark
http://www.coker.com.au/~russell/  My home page

--
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.
#8 lore raw
Quoted 1 line · --- Russell Coker

can_ps(staff_t, domain) probably does what you want.

That seems to have done it. Thanks!

_______________________________
Do you Yahoo!?
Declare Yourself - Register online to vote today!
http://vote.yahoo.com

--
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.

#9 lore raw
In reply to Tom Anderson
Quoted 9 lines · Tom Anderson

Can anyone explain the purpose/benefit of having an account under the staff_r role? I thought it was to allow limited administrative functions, but I've discovered that it doesn't even allow reading the logfiles under /var/log/. What purpose does it serve, other than to limit who can transition to sysadm_r?

SE Linux appears to be quite powerful, but dear $deity it's confusing. I'd sell my soul for a nice, readable O'Reilly Press title covering this stuff!

Some weeks ago when googling about for some docs (that is: Beginner docs) I stumbled over this site:

http://www.lurking-grue.org/

For me, a beginner with selinux, the most usable I found so far.

[ Thanks, Faye Coker ]

HTH

Wolfgang

Signature · 8 lines
Wolfgang Pfeiffer                           gpg ID: 0AA7E825 
Profile, links: http://profiles.yahoo.com/wolfgangpfeiffer


--
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.