Linux/PAM and htpasswd

From Omnia
(Redirected from Linux PAM and htpasswd)
Jump to navigation Jump to search


www.centos.org - Forums - CentOS 5 - Application & Software Support - Does anyone know of an existing pam_pwdfile RPM for Centos 5.2?:

For those of you who have to remain on centos 5.2 for whatever reason ( i.e. don't have the option to upgrade to 5.4 or 5.3 ) here's how i managed to build pam_pwdfile on 5.2:

Build using PAM 0.77 source and pam_pwdfile-0.99.tar.gz , following the excellent instructions at http://www.productionmonkeys.net/guides/ftp-server/vsftpd

here's the relevant bits from the above URL :

wget http://www.kernel.org/pub/linux/libs/pam/pre/library/Linux-PAM-0.77.tar.bz2
bunzip2 -c Linux-PAM-0.77.tar.bz2 | tar -xvf -
cd Linux-PAM-0.77/modules
wget http://cpbotha.net/files/pam_pwdfile/pam_pwdfile-0.99.tar.gz
tar zxvf pam_pwdfile-0.99.tar.gz
cd ..
rm default.defs
ln -s defs/redhat.defs default.defs
make all
cp modules/pam_pwdfile-0.99/pam_pwdfile.so /lib/security (or /lib64/security )

N.B. One extra step was needed before the "make all" when building on x86_64 :
add -fPIC to configure.in so it now reads :
case $OS in
linux) OS_CFLAGS=”-ansi … -pedantic -fPIC”

hope that helps someone else avoid the 5+ hours i spent on this



vsftpd | Production Monkeys