LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   su user (https://www.linuxquestions.org/questions/linux-newbie-8/su-user-4175437902/)

ust 11-19-2012 11:52 PM

su user
 
I would like to have a special user that can su all general user , but this special user do not have other root permission but only can do su , is that possible to have such user ?


thanks

malekmustaq 11-20-2012 12:32 AM

You can do it out of any normal $USER so long as he knows the passwd of all other regular users to whom he shall su to. When this su-ing user attempts to su to root the password thereto he must not know, so that he cannot obtain root user privilege; also, this su-ing regular user must have NO "sudo" power: i.e. he is not listed in the /etc/sudoers list. Just make sure that the filesystem he is working to allows him to set user id.

You can try that if it works. It works in my Slackware.

Hope that helps.

Good luck.

RaviTezu 11-20-2012 06:36 AM

I guess /etc/sudoers may help you.
 
Try learn the syntax of the /etc/sudoers file.

& you will get it.

TB0ne 11-20-2012 09:56 AM

Quote:

Originally Posted by ust (Post 4833016)
I would like to have a special user that can su all general user , but this special user do not have other root permission but only can do su , is that possible to have such user ?

Is it possible for you to even say "thanks" after people help you, post a solution after you get help, or even acknowledge people replied to you?? Because you've NEVER done that so far.

Read the man page on the sudo command, and pay attention to the -u option. Set the sudoers file up accordingly.


All times are GMT -5. The time now is 07:50 AM.