as5 vsftpd限制登录用户访问目录方案1、vi /etc/vsftpd/vsftpd.conf
增加一行
chroot_local_user=YES
#limit user only Accessc its own Directory.
2、重启启动vsftpd服务
# /etc/init.d/vsftpd restart
备注:重启服务之后,FTP所有用户都将受限制只能访问他们home目录的文件
附:/etc/vsftpd/vsftpd.conf的配置说明(转载)
# Example config file /etc/vsftpd/vsftpd.conf
#
# The default compiled in settings are fairly paranoid. This sample file
# loosens things up a bit, to make the ftp daemon more usable.
# Please see vsftpd.conf.5 for all compiled in defaults.
#
# READ THIS: This example file is NOT an exhaustive list of vsftpd options.
# Please read the vsftpd.conf.5 manual page to get a full idea of vsftpd's
# capabilities.
#
# Allow anonymous FTP?
anonymous_enable=NO 是否允许匿名ftp,如否则选择NO
# Uncomment this to allow local users to log in.
local_enable=YES 是否允许本地用户登录
# Uncomment this to enable any form of FTP write command.
write_enable=YES 开放本地用户的写权限,这个选项可以控制FTP 的指令是否允许更改file system,譬如STOR、DELE、RNFR、
Copyright © IT之家(Www.IT55.Com) Powered By 易网科技 备案号:豫ICP备07012916号
本站QQ群:6614136 / 4218001 友情链接QQ:987950121