SSH no interactive shell, scp, sftp, socks
<br><br>
I'm using Ubuntu server on my vps,
i made an automated script to create users when they register on my site and i want users to be able to only use the -D xxx for socks dynamic port forwarding and use both password and public key.
<br><br>what i need is:

1.disable interactive shell (server side) so users cant write anything in the terminal window:<br>
i did that with a loop inside a "no_shell" file that exits the terminal window when the user presses the return key, using the >usermod -s /..../no_shell [user]<, is there something better ?

2.disable user from using sftp and scp altogether or if not possible (from all the forums i read) at least limit there sftp & scp browsing to there [/home/user] folder.

i tried the "limits.conf" "chroot" but it broke the "no_shell" thing & the home dir in "passwd" could not be reached.
<br>i also tried the >ChrootDirectory /home/%u< in "sshd_config" also had some no_shell issues

3.is there a way to limit each users bandwidth and speed from dynamic forwarding as in 512kbps and 4GB per month ?

all these should be server side lets say i dont trust the users.<br>
im only 1 week into linux. but learning fast, so dont hesitate to drop the big bombs.
SSH no interactive shell, scp, sftp, socks
===

<br><br>
I'm using Ubuntu server on my vps,
i made an automated script to create users when they register on my site and i want users to be able to only use the -D xxx for socks dynamic port forwarding and use both password and public key.
<br><br>what i need is:

1.disable interactive shell (server side) so users cant write anything in the terminal window:<br>
i did that with a loop inside a "no_shell" file that exits the terminal window when the user presses the return key, using the >usermod -s /..../no_shell [user]<, is there something better ?

2.disable user from using sftp and scp altogether or if not possible (from all the forums i read) at least limit there sftp & scp browsing to there [/home/user] folder.

i tried the "limits.conf" "chroot" but it broke the "no_shell" thing & the home dir in "passwd" could not be reached.
<br>i also tried the >ChrootDirectory /home/%u< in "sshd_config" also had some no_shell issues

3.is there a way to limit each users bandwidth and speed from dynamic forwarding as in 512kbps and 4GB per month ?

all these should be server side lets say i dont trust the users.<br>
im only 1 week into linux. but learning fast, so dont hesitate to drop the big bombs.