PDA

View Full Version : chroot / vsftpd


andre
3rd May 2005, 11:03
I'm using vsftpd as my FTP server, and I'd like to chroot my FTP users to their home dir. How can I do it?

Andre

falko
3rd May 2005, 12:18
Put

passwd_chroot_enable=YES

in

/etc/vsftpd.conf and restart vsftpd. That chroots each user to the directory specified in /etc/passwd. If you want to chroot a user to another directory than his home directory, simply put a dot (.) in the path to his home directory in /etc/passwd:

admin:x:1000:1000:admin:/home/./admin:/bin/bash

would chroot the user admin to /home instead of /home/admin.