Here is what I want:

SFTP access, to put and get files. User probably needs the basics such as 'ls' etc.

I do not want the user to be able to say, cd /var/www/html and GET someones site or otherwise mess with my server.

Here is what I did:

I followed this, and checked it twice I must be close, because I can actually log in with my chrooted user, but then I get:

myuser@localhost's password:
/bin/chrootshell: Exec format error
Connection to localhost closed

(same if I go to

I see in the logs that either way, user is authenticated, so I must have my shell enviroment bad and it fails. I dont know if this is dist. specific issue, or just a standard mistake, but I am now officially over my head.

I am soing this on Mandrake 10.1 official.

Thanks fro any help!

And heres is what I ended up using. JailKit from it is a bit Debian Specific so you need to make a few adjustments if you use say, Mandrake like I do, but it really makes the whole process much easier.