转:http://ift.tt/1S4YppC

在Redhat AS4里按照默认方式安装好vsftpd后,按照以下步骤配置:
gedit /etc/vsftpd/vsftpd.conf
在文件中限制匿名用户,做如下设置:
anonymous_enable=NO
userlist_enable=YES
userlist_deny=NO
userlist_file=/etc/vsftpd.user_list

这样只有在user_list 里面的用户才可以访问ftp。
但是在service vsftpd restart 后,
用ftp localhost 测试,输入正确的用户名和密码之后,
却一直显示
:530 Login incorrect
Login Failed
后来发现在etc下面有个pam.d文件夹
进去打开vsftpd这个文件, 发现里面对之前的用户进行了限制,
将里面对应的限制注释掉,问题解决。

不好意思,这是vsftpd中的内容,再次感谢!
# Standard behaviour for ftpd(8).
auth required pam_listfile.so item=user sense=deny file=/etc/ftpusers onerr=succeed

# Note: vsftpd handles anonymous logins on its own. Do not enable
# pam_ftp.so.
# Standard blurb.
@include common-account
@include common-session

@include common-auth
auth required pam_shells.so

http://ift.tt/1Pb0exF

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s