vsftpd virtual users
I'm trying to set vsftpd up with virtual users. I've been poking around various how-tos and have yet to be successful. here is the output of the files that I am using:
/etc/pam.d/vsftpd:
#%PAM-1.0
auth required pam_pwdfile.so pwdfile /etc/vsftpd/passwd
account required pam_permit.so
#session optional pam_keyinit.so force revoke
auth required pam_listfile.so item=user sense=allow file=/etc/vsftpd/ftpusers onerr=succeed
#auth required pam_shells.so
#auth include system-auth
#account include system-auth
#session include system-auth
session required pam_loginuid.so
(made with htpasswd)
/etc/vsftpd/passwd:
bob:L1hoRLK5BJJnA
/etc/vsftpd/vsftpd.conf:
this one is long but the things that I have changed are:
pam_service_name=vsftpd
userlist_enable=YES
tcp_wrappers=YES
user_sub_token=$USER
local_root=/var/www/sites/$USER
guest_enable=YES
guest_username=ftp
I might have missed one or two somewhere in there.
finally if I try logging in with bob I get this:
ftp 127.0.0.1
Connected to 127.0.0.1.
220 (vsFTPd 2.0.5)
530 Please login with USER and PASS.
530 Please login with USER and PASS.
KERBEROS_V4 rejected as an authentication type
Name (127.0.0.1:root): bob
331 Please specify the password.
Password:
530 Login incorrect.
Login failed.
I've been banging my head on this one for awhile. without much success. I've been restarting the vsftpd every time I do something, and it does seem that the pam is connected (when I comment out the first two lines I can login with local users). I'm really lost on this one, and any help would be awesome.
Thank you much,
Michael
|