VSFTPD 配置
VSFTPD 配置
?
Ubuntu中vsftpd的配置文件為/etc/vsftpd.conf
1. 限制用戶登陸到home路徑下的指定文件夾
為了指定用戶登錄ftp后的路徑,默認(rèn)的路徑是用戶的home路徑,想要修改下,修改到其home路徑下的ftp路徑中即:/home/username/ftp,在vsftpd.conf中添加下列語句:
?
user_sub_token=$USER
local_root=/home/$USER/ftp
?
修改完成后,重啟服務(wù)即可
?
2. 限制用戶登錄ftp后,只能訪問當(dāng)前路徑,無法訪問上層路徑
chroot_local_user=NO
allow_writeable_chroot=YES
chroot_list_enable=YES
chroot_list_file=/etc/vsftpd/vsftpd.chroot_list
chroot_local_user 為NO,chroot_list_enable 為YES表示只有vsftpd.chroot_list中的用戶受限
chroot_local_user 為YES,chroot_list_enable 為NO? 表示所有用戶都受限
chroot_local_user 為YES,chroot_list_enable 為YES表示只有vsftpd.chroot_list中的用戶都不受限
chroot_local_user 為NO,chroot_list_enable 為NO表示所有用戶都不受限
?
?
?
總結(jié)
- 上一篇: LaTeX符号语法总结
- 下一篇: 电气工程cad实用教程电子版_电气工程C