Make pure-ftpd work with authentication

Nov 20, '03 09:29:00AM

Contributed by: idaniel

If you need to get pure-ftpd working with OS X, you need to use PAM. In order to make PAM work, you'll need to do the following (for now):

 % ln -s /usr/include/pam /usr/include/security
Then configure and build pure-ftpd (you can play with options to configure, this is just a example):
 % ./configure --with-everything --with-paranoidmsg 
 --without-capabilities --with-virtualchroot --with-pam
 % make install
Create a /etc/xinetd.d/ftp file similar to this one (this one allows root access for testing only):
service ftp
{
        disable = no
        socket_type     = stream
        wait            = no
        user            = root
        server          = /usr/local/sbin/pure-ftpd
        server_args     = -A -E -lpam
        groups          = yes
        flags           = REUSE
}
Create a /etc/pam.d/pure-ftpd file:
# pure-ftpd: auth account password session
auth       required       pam_nologin.so
auth       sufficient     pam_securityserver.so
auth       sufficient     pam_unix.so
auth       required       pam_deny.so
account    required       pam_permit.so
password   required       pam_deny.so
session    required       pam_uwtmp.so
Restart xinetd:
 % kill -HUP `cat /var/run/xinetd.pid`
That should be enough to make it work.

Comments (4)


Mac OS X Hints
http://hints.macworld.com/article.php?story=20031113075452804