LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Disabeling Shell Access in OpenSSHd (https://www.linuxquestions.org/questions/linux-software-2/disabeling-shell-access-in-opensshd-406778/)

wwnexc 01-23-2006 12:14 AM

Disabeling Shell Access in OpenSSHd
 
Hi,

I am wondering how i can disable shell access for some users of my openssh server.

I only want users to be able to log in and use port forwarding.

Thanks!!

tlowk 02-14-2006 02:03 PM

in /etc/passwd

give them sleepshell as a shell
see http://www.mariovaldez.net/software/sleepshell/

the port forwarding will keep the connection open


another trick can be in their .bash_login you test
for on of the ssh variables and exit when it is not ""

if [ -n "$SSH_CONNECTION" ]
then
exit
fi

best regards,

Tlowk


All times are GMT -5. The time now is 02:54 PM.