Use sudo su - <username> to access the <username's> account but sudo su - shouldn't be possible with a sudo user
Posted
by
Winnie
on Stack Overflow
See other posts from Stack Overflow
or by Winnie
Published on 2013-11-06T09:42:26Z
Indexed on
2013/11/06
9:53 UTC
Read the original article
Hit count: 127
There is a requirement I got. My sudo users (for which their entry in sudoers file) should be able to access other user's account say Oracle using following command:
sudo su - Oracle
The above should work with giving current users password.
But if the same user is firing the following command,
sudo su -
it shouldn't work and thus root access shouldnt be given to current user.
I am not using su because because i dont want current user to know the credentials of other user(root,Oracle etc.). Can anyone please help me . Its urgent...
© Stack Overflow or respective owner