%define name checkpassword-pam %define version 0.99 %define release 1mdk Summary: A checkpassword compatible authentication program Name: %{name} Version: %{version} Release: %{release} License: GPL Group: System/Servers URL: http://checkpasswd-pam.sourceforge.net/ Source: %{name}-%{version}.tar.bz2 BuildPreReq: pam-devel Provides: checkpassword BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot %description checkpassword-pam is an implementation of checkpassword-compatible authentication program. Checkpassword is described in <URL:http://cr.yp.to/checkpwd.html> checkpassword-pam was written from scratch. There are several older packages called checkpassword-pam, derived from DJB's checkpassword code. This checkpassword-pam is more modern and administrator-friendly. If you are using Linux-PAM, make sure it is more recent than 0.59. Incompatibilities are in the PAM conversation function (number of requests vs number of responses). All modern Linux distribution use PAM newer than that. %prep %setup -q %build %configure2_5x %make %install [ "%{buildroot}" != "/" ] && rm -rf %{buildroot} install -d %{buildroot}/bin install -d %{buildroot}%{_sysconfdir}/pam.d install -d %{buildroot}%{_mandir}/man8 install -m755 checkpassword-pam %{buildroot}/bin/ install -m644 checkpassword-pam.8 %{buildroot}%{_mandir}/man8/ # This is taken from %{_sysconfdir}/pam.d/login # I hope this is sufficent? cat > %{buildroot}%{_sysconfdir}/pam.d/checkpassword-pam << EOF #%PAM-1.0 auth required /lib/security/pam_securetty.so auth required /lib/security/pam_stack.so service=system-auth auth required /lib/security/pam_nologin.so account required /lib/security/pam_stack.so service=system-auth password required /lib/security/pam_stack.so service=system-auth session required /lib/security/pam_stack.so service=system-auth session optional /lib/security/pam_console.so EOF chmod 644 %{buildroot}%{_sysconfdir}/pam.d/checkpassword-pam %clean [ "%{buildroot}" != "/" ] && rm -rf %{buildroot} %files %defattr(-, root, root) %doc AUTHORS NEWS README interface.html %attr(644,root,root) %config(noreplace) %{_sysconfdir}/pam.d/checkpassword-pam %attr(755,root,root) /bin/checkpassword-pam %attr(644,root,root) %{_mandir}/man8/checkpassword-pam.8* %changelog * Sat Nov 13 2004 Oden Eriksson <oeriksson@mandrakesoft.com> 0.99-1mdk - 0.99 * Wed Oct 01 2003 Oden Eriksson <oden.eriksson@kvikkjokk.net> 0.98-1mdk - 0.98 * Mon Aug 04 2003 Oden Eriksson <oden.eriksson@kvikkjokk.net> 0.97-1mdk - 0.97 - use the %%configure2_5x macro * Sat Jul 12 2003 Oden Eriksson <oden.eriksson@kvikkjokk.net> 0.96-1mdk - 0.96 * Thu Jul 10 2003 Oden Eriksson <oden.eriksson@kvikkjokk.net> 0.95-2mdk - rebuild * Mon Jan 27 2003 Oden Eriksson <oden.eriksson@kvikkjokk.net> 0.95-1mdk - initial cooker contrib