1

I want to setup a small FTP server for personal use, and decided to use vsftpd for that. I thought that I should enable chroot_local_user, so users are chrooted to their home directory upon login. Although all users should not have read access outside their home directory, you are never safe from mistakes, right?

But man vsftpd.conf says:

chroot_local_user
    If set to YES, local users will be (by default) placed in a chroot() jail in
    their home directory after login.  Warning: This option has security
    implications, especially if the users have upload permission,  or  shell
    access.  Only enable if you know what you are doing.  Note that these
    security implications are not vsftpd specific. They apply to all FTP daemons
    which offer to put local users in chroot() jails.

What "security implications" do they mean? Do I have to remove the write permission of each user on it's home directory? Why is that? I can't imagine it's safer to not use chroot than to use it...

  • 1
    It is not that is unsafer than the alternative solution, it is just that is not perfect isolation and chroots can be broken. – Rui F Ribeiro Apr 18 '18 at 11:38
  • I have worked for a $1b+ company that did exactly this... on the other hand, I would hardly say that made it the best idea... – Art Hill Apr 18 '18 at 14:34
0

You can configure a chroot jail that almost impossible to break out of, but that wont stop an attacker doing things such as gaining local network access or sending spam or forcing the system into a bot net. A chroot jail will keep them from getting root access but plenty of damage can be done from a standard user account. If the server is only for personal use than chroot should be more than enough security IMHO.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.