SFTP User throttling settings

Source: Internet
Author: User

First identify a few things before you start the operation

(1) Determine the sshd version is higher than 4.8

(2) Confirm that SELinux is off, or authorize the corresponding directory

(3) Be sure to follow the steps otherwise there may be permissions issues

(4) The following command uses root operation


1. Create an SFTP user group

Groupadd sftpusers

2. Create a directory that specifies to block

mkdir/home/sftp/sunsun/

3. Create a user and specify the directory of the user's home directory as chroot

Useradd-s/bin/false-g sftpusers-d/home/sftp/sunsun/sunsun

4. Set the password

passwd Sunsun

5. Create an Upload directory

Mkdir/home/sftp/sunsun/upload

6. Authorized user permissions on this directory

Chown Sunsun:sftpusers/home/sftp/sunsun/upload

7. Modify the SSHD profile---a few lines of content added to the profile are best added at the end of the configuration file, or you might see the following error message "*usedns*"

Vim/etc/ssh/sshd_config (edit this directory)

Subsystem sftp internal-sftp

Match Group Sftpusers

Chrootdirectory%h

Forcecommand internal-sftp

Allowtcpforwarding No

X11forwarding No

Restart the SSHD service after Setup is complete


This article is from the "Horse Walking Day" blog, please be sure to keep this source http://mazouri.blog.51cto.com/9764673/1760353

SFTP user throttling settings

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.