0

I'm trying to have some users able to sftp but not ssh. I've looked at OpenSSH: Difference between internal-sftp and sftp-server and Trying to ChrootDirectory an SFTP user to their home directory

Inside of sshd_config I have the lines

 Subsystem sftp internal-sftp
 AllowUsers <a bunch of users>

 Match group sftponly
      ChrootDirectory /home/%u
      X11Forwarding no
      AllowTcpForwarding no
      ForceCommand internal-sftp

Filezilla gives me

 Error: Network error: Software caused connection abort
 Error: Could not connect to server

When I comment out the ChrootDirectory /home/%u I am able to connect fine.

How can I chroot?

1 Answers1

1

I'm going to go out on a limb here and guess it's file permissions. If you use ChrootDirectory everything in the path following needs to be owned by root and not group writable (see man sshd_config).

And just to make sure, you did add your users to group sftponly and all that stuff...

quadruplebucky
  • 5,314
  • 24
  • 24