View previous topic :: View next topic |
Author |
Message |
petrjanda Veteran
Joined: 05 Sep 2003 Posts: 1557 Location: Brno, Czech Republic
|
Posted: Sun Jul 27, 2008 4:25 am Post subject: sudo: how to do this? |
|
|
I need to allow sudo root access with commands like rm, vi, less, more, mkdir and nano for a person, but only in the directory /usr/websites.
How can I do this?
Thanks,
Petr _________________ There is, a not-born, a not-become, a not-made, a not-compounded. If that unborn, not-become, not-made, not-compounded were not, there would be no escape from this here that is born, become, made and compounded. - Gautama Siddharta |
|
Back to top |
|
|
bunder Bodhisattva
Joined: 10 Apr 2004 Posts: 5947
|
Posted: Sun Jul 27, 2008 4:32 am Post subject: |
|
|
Moved from Off the Wall to Networking & Security. _________________
Neddyseagoon wrote: | The problem with leaving is that you can only do it once and it reduces your influence. |
banned from #gentoo since sept 2017 |
|
Back to top |
|
|
aronparsons Tux's lil' helper
Joined: 04 Oct 2004 Posts: 117 Location: Virginia
|
Posted: Sun Jul 27, 2008 7:55 am Post subject: |
|
|
I'd be wary of using sudo for this. Groups and permissions would probably be a better solution in a directory that probably doesn't hold system-related files.
If you really want to do this on root owned files and sudo, you'll want to make use of the NOEXEC option for programs that allow commands to be run from within them (e.g. Vi). You can configure the commands allowed in sudo to be something like "/usr/bin/vim /usr/websites/*", but it will require the full path to the file to be used. |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|