About sudo
I want to let a user (eg. userA)have the permission to su another user (eg. userB), I would like to ask if I release the sudo function to userA , userA except can su to userB , whether userA have full function as root ?
thx |
Quote:
|
if you examine the syntax of /etc/sudoers, you'll discover it allows limitation in (originating) hosts, users and commands. You can execute sudo not only so that the instructions are executed as root, but also so the instructions (commands) are executed as another user:
Code:
sudo [-u <username>] <command> Code:
userA ALL=( userB ) /bin/ls, /bin/cat Code:
sudo -u userB /bin/cat ~userB/.ssh/id_dsa If however you want that user to be able to su as that user, you could inscribe Code:
userA ALL=( userB ) /bin/bash Code:
sudo -u userB -s Code:
sudo -u userB /bin/bash -i |
All times are GMT -5. The time now is 07:34 PM. |