home | list info | list archive | date index | thread index

[OCLUG-Tech] jailing users?

Hi folks,

I'm trying to find out if there is a way to jail users in the /home/$USER?
I am trying to set up a server that simply allows users to sftp to some
server and to retrieve files.

What I mean is this:

I have user called test.

passwd file would look like this:

test:x:1002:1002:Jerry,,,:/home/test:/usr/lib/sftp-server
(/home is a nfs mount)

Ok this works so far, user "test" sftp to server and he/she is able to
create/delete files.

How do I disable/prevent user from doing this: "cd .." "cd /"? Basically
leaving there home directory and view other peoples directories in /home?

I know if permissions are set correctly other users cannot see into each
other home directories. But I just want to prevent shell
access/hacking/playing.

Any thoughts?

thnks
jerry