RE: SELinux newbie help please

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> From: selinux-bounces@xxxxxxxxxxxxxxxxxxxxxxx [mailto:selinux-
> bounces@xxxxxxxxxxxxxxxxxxxxxxx] On Behalf Of Alain Williams
> 
> I want one user to, on login, run a script setuid root -- it needs to be able to
> read all files in one part of the file system to back that part up to an externally
> mounted USB drive.
> 
> I have a small setuid root program (written in C) that just runs the shell script.

This doesn't sound like a selinux thing.  It sounds like you should probably just use sudo.  You should be able to add the "sudo /path/to/some/script" into your .bash_login or something like that.

Sudo is a setuid root program (written in C) that allows you to run other things as other users.  It's highly stable and secure, probably much more reliable and secure than the average homegrown C setuid root program.  ;-)

You can configure sudo using the "visudo" command as root.  You can configure the behavior you want by adding a line like this:
awilliam    ALL=(ALL) NOPASSWD: /path/to/some/script

--
selinux mailing list
selinux@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/selinux



[Index of Archives]     [Fedora Users]     [Fedora Desktop]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Campsites]     [KDE Users]     [Gnome Users]

  Powered by Linux