关于VSFTPD
vsFTPD是一款小巧易用FTP服务器程序,官方网站:http://vsftpd.beasts.org/
安装
yum -y install vsftpd
配置
ftp帐号添加
usermod -s /sbin/nologin 15099net 使用此语句ssh不能登陆,ftp可以登录
usermod -s /bin/false 15099net 使用此语句ftp不能登陆
usermod -s /bin/bash 15099net 使用此语句ftp能登录,ssh也能登录
这里添加一个ftp帐号:15099net,密码为:15099net帐号的主目录:/var/www/html
adduser -m -d /var/www/html -s /sbin/nologin 15099net
passwd 15099net
配置文件修改
mv /etc/vsftpd/vsftpd.conf /etc/vsftpd/vsftpd.conf.bak
egrep -v '^$|^#' /etc/vsftpd/vsftpd.conf.bak
vi /etc/vsftpd/vsftpd.conf
anonymous_enable=No
chroot_local_user=YES
chroot_list_enable=YES
chroot_list_file=/etc/vsftpd/chroot_list
touch /etc/vsftpd/chroot_list
启动vvsftp
/etc/init.d/vsftpd start
chkconfig --level 345 vsftpd on
没有评论 :
发表评论