Possible Duplicate:Creating a UNIX account which only executes one command I am trying to setup a user account that only has as minimal rights as possible.The user should be able to log in via SSH and then use the su command to get root access BUT nothing else.Is this even possible? So no basic commands like cd, ls or mkdir should be available! The user should only be able to see one empty folder and then be able to use the su command to get full system access of the real OS (if chroot is used to achieve this).Any ideas how this could be achieved?Thanks in advance!
SSH minimal rights user - su only
debian;users;chroot;su;jails
I would suggest allowing to connect only via public key. Then you can connect that public key with your own command by supplying it in ~/.ssh/authorized_keys like that:command=/path/to/mycommand ssh-rsa ...Whenever the user logs into that account with that key your command is executed instead of the usual shell. That command can for example be a shell script, or even just something like su -.That should do what you asked for. - But please think again, it that is really what you want.