分类: LINUX
2009-07-03 11:00:24
auth required /lib/security/pam_userdb.so db=/etc/vsftpd/ftpuser
account required /lib/security/pam_userdb.so db=/etc/vsftpd/ftpuser
useradd virtual -d /home/ftp -s /bin/false
chown virtual:virtual /home/ftp
修改vsftpd.conf
listen=YES
anonymous_enable=NO
chroot_local_user=YES
guest_enable=YES
guest_username=virtual
user_config_dir=/etc/vsftpd
pam_service_name=vsftpd.vu
local_enable=YES
用户没有下载权限,限定目录其他删除权限都有
local_root=/home/wwwroot/xx
download_enable=no
#virtual_use_local_privs=NO
#write_enable=YES
#anon_upload_enable=yes
#anon_other_write_enable=no
#anon_mkdir_write_enable=yes
#anon_world_readable_only=no
anon_upload_enable=yes
anon_mkdir_write_enable=yes
anon_other_write_enable=yes
anon_world_readable_only=no在vstpd 目录里创建虚拟用户的配置文件 。配置文件名必须和用户名相同例如zhou的用户名write_enable=YES
anon_world_readable_only=NO
anon_upload_enable=YES
anon_mkdir_write_enable=YES
anon_other_write_enable=YES
local_root=/var/www/htmlchown -R virtual /var/www/html