Chroot for SFTP on OpenSUSE

1. Add chroot to SSHD Configuration file
vi /etc/ssh/sshd_config

Match Group uploaders,!admin
  X11Forwarding no
  AllowTcpForwarding no
  ForceCommand internal-sftp
  ChrootDirectory /home/uploaders

Match User cacti Address *,!
  ForceCommand /bin/false
2. Mount directory to home directory
vi /etc/fstab

/home/www/ /home/uploaders/ none bind 0 0


Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.