paul Posted June 26, 2006 Report Share Posted June 26, 2006 Who is an sudo guru? I want to enable users to sudo an application with only specific prameters example: whoami paul sudo ls ~paul <insert dir listing here> sudo ls ~tyme paul isn't allowed to view ~tyme Perhaps directories aren't the best example .. here's another: whoami paul sudo /usr/bin/myscript -p -o -i -u -y 'paul' script completed !!! sudo /usr/bin/myscript -p -o -i -u -y 'tyme' paul isn't allowed to run myscript with tyme as a parameter how do I setup sudo to allow this? I've tried the following %users localhost= NOPASSWD: /usr/bin/myscript -p -o -i -u -y `whoami` but it didn't seem to work :( Quote Link to comment Share on other sites More sharing options...
tyme Posted June 27, 2006 Report Share Posted June 27, 2006 only thing that immediately pops out at me is syntax...i.e.: %users localhost= NOPASSWD: /usr/bin/myscript -p -o -i -u -y '`whoami`' but perhaps you've tried that and i'm completely out of my wits... Quote Link to comment Share on other sites More sharing options...
paul Posted June 27, 2006 Author Report Share Posted June 27, 2006 so far it looks like I have to go thru eachuser paul localhost= NOPASSWD: /usr/bin/myscript -p -o -i -u -y paul tyme localhost= NOPASSWD: /usr/bin/myscript -p -o -i -u -y tyme I tried this with hope ... %users localhost= NOPASSWD: /usr/bin/myscript -p -o -i -u -y %u but to no avail oh well .. I guess I document it so I do forget in the future :) Quote Link to comment Share on other sites More sharing options...
tyme Posted June 27, 2006 Report Share Posted June 27, 2006 'tis a pitty :-/ there's gotta be a way to do it though... Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.