sftp-server with defaultroot

Marten Lehmann lehmann at cnm.de
Fri Jun 8 02:28:02 EST 2007


I searched a while to find out, if there is an sftp-server 
implementation which provides an option similar to the defaultroot of 

A typical use would be:

DefaultRoot = ~

The option does the follwing:

Once the use logs in, it determines the home directory of the user .ie 
/home/u1234 and takes this as the users root. The user cannot escape 
that root (he can not look at /tmp for example). Each file within his 
home directory is presented without the home directory prefix (for 
example: /index.html instead of /home/u1234/index.html).

This is very different from the chroot options, because there is no need 
to have all the libraries and executables within the users home directory.

The projects that I found look very strange and not good maintained. 
Interestingly they are based on the sftp-server of ssh.

Why doesn't the openssh sftp-server include this? Are there plans to do 
it? Are there certain reasons not to include?


More information about the openssh-unix-dev mailing list