LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Security (https://www.linuxquestions.org/questions/linux-security-4/)
-   -   Creating a login shell using sudoshell (https://www.linuxquestions.org/questions/linux-security-4/creating-a-login-shell-using-sudoshell-565249/)

edcrozer 06-28-2007 10:06 PM

Creating a login shell using sudoshell
 
Hi,

I've just finished installing sudoshell for some of the more important server. We're using the combination of sudo with sudoshell, so we can audit everything a user is doing when opening a shell as root or oracle.

My question is....


Is there a way to use sudoshell as the default login shell. I would like to force all users loging into the server with there username to automatically start the shell using susoshell.

I've thought about putting the "/bin/sudo /usr/bin/sudoshell -u $USER -" in to the local ~/.profile of each user, but would love to just change the the default login shell.

Micro420 06-28-2007 10:56 PM

I guess you could edit the /etc/passwd for each respective user? If you want the login shell to be for the entire system, maybe look at the /etc/profile? I'm just totally guessing and I am probably wrong, but it's better than nothing!

edcrozer 06-28-2007 11:20 PM

Yes I want to change the default login shell in the passwd file. How do I pass the user name to the sudoshell.

example:

1. I login in as edward
2. the login calls what ever shell is specified in the /etc/passwd (usually /bin/bsh) for this example /usr/bin/sudoshell
3. the login starts sudoshell and goes directly to a root shell

I would like to use sudoshell for each user (sudoshell -u edward -) how do you pass the parameters for each user.


All times are GMT -5. The time now is 03:37 AM.