Created
November 19, 2012 16:50
-
-
Save fgbreel/4111804 to your computer and use it in GitHub Desktop.
SFTP with OpenSSH
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Subsystem sftp "internal-sftp -u 0002" | |
Match Group sftponly | |
ChrootDirectory %h | |
AllowTCPForwarding no | |
X11Forwarding no | |
ForceCommand internal-sftp -u 0002 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Remove from
/etc/ssh/sshd_config
any line containingsftp
Put the content above at the end of the file
/etc/ssh/sshd_config
execute the commands below to create a group who will be matched on the rule of the snippet above, an user, and the correct directory permissions.