[sisyphus] íàñòðîéêà virtual users â vsftpd è pam_userdb
ioka
=?iso-8859-1?q?ioka_=CE=C1_mail15=2Ecom?=
þÔ á×Ç 28 21:37:02 MSD 2003
çäðàâñòâóéòå..
ïðîáëåìà ñ íàñòðîéêîé virtual users â vsftpd
ñèñòåìà Master 2.2 + Sisyphus 27.08.2003
vsftpd-1.1.2-alt3
ñäåëàíî áûëî ñëåäóþùåå (òàê êàê ýòî îïèñàíî â
äîêóìåíòàöèè):
# db_load -T -t hash -f /etc/vsftpd/logins.txt
/etc/vsftpd/vsftpd_login.db
( # rpm -qa libdb*
libdb1-1.85-alt2
libdb4.0-doc-4.0.14-alt10
libdb2-2.4.14-alt2
libdb4.0-4.0.14-alt10
libdb3-3.3.11-alt8
# rpm -qa db*
db2-utils-2.4.14-alt2
db1-utils-1.85-alt2
db4.0-utils-4.0.14-alt10 )
# chmod 600 /etc/vsftpd/vsftpd_login.db
äîáàâëåíû â /etc/pam.d/vsftpd ñëåäóþùèå 2 ñòðîêè (ñ
íà÷àëà):
# cat /etc/pam.d/vsftpd
#mine
auth required /lib/security/pam_userdb.so
db=/etc/vsftpd/vsftpd_login
account required /lib/security/pam_userdb.so
db=/etc/vsftpd/vsftpd_login
#%PAM-1.0
#auth required pam_userpass.so
#auth include system-auth-use_first_pass
#auth required pam_listfile.so item=user
sense=deny file=/etc/ftpusers onerr=succeed
#auth required pam_securetty.so
#auth required pam_shells.so
#auth required pam_nologin.so
#account include system-auth
#password required pam_deny.so
#session required pam_deny.so
# useradd -d /home/ftpsite virtual
ïðè ýòîì íàñòðîéêè áûëè òàêèå:
# cat /etc/vsftpd/conf
anonymous_enable=NO
local_enable=YES
write_enable=NO
anon_upload_enable=NO
anon_mkdir_write_enable=NO
anon_other_write_enable=NO
user_config_dir=/etc/vsftpd/user_conf
chroot_local_user=YES
guest_enable=YES
guest_username=virtual
connect_from_port_20=YES
nopriv_user=novsftpd
max_clients=2
ascii_upload_enable=YES
ascii_download_enable=YES
ïðè ýòîì îáû÷íûé ïîëüçîâàòåëü, çàðåãèñòðèðîâàííûé â
ñèñòåìå, ìîæåò ñâîáîäíî ðàáîòàòü, à âèðòóàëüíûé íåò:
Aug 28 17:07:21 lin pam_userdb[25207]: could not obtain
password for `1' (ñ çàêîìåíòèðîâàííûìè ñòðîêàìè â
/etc/pam.d/vsftpd, ñîîòâåòñòâåííî)
è
Aug 28 16:29:25 lin pam_userdb[24003]: could not obtain
password for `1'
Aug 28 16:29:26 lin pam_tcb[24003]: vsftpd:
Authentication failed for UNKNOWN USER from (uid=0)
(áåç êîììåíòèðîâàíèÿ)
÷òî íåîáõîäèìî ñäåëàòü äîïîëíèòåëüíî??
Ç.Û. ïîìíèòüñÿ â ðåäõàòå âñå ïðåêðàñíî ðàáîòàëî..
--
ñ Óâàæåíèåì, ioka
ðÏÄÒÏÂÎÁÑ ÉÎÆÏÒÍÁÃÉÑ Ï ÓÐÉÓËÅ ÒÁÓÓÙÌËÉ Sisyphus