%define shadowgroupid 15 Name: pwdutils Version: 3.2.19 Release: 3mamba Summary: A collection of utilities to manage the passwd and shadow user information Group: System/Tools Vendor: openmamba Distribution: openmamba Packager: Silvan Calarco URL: http://www.thkukuk.de/pam/pwdutils/ Source: https://build.opensuse.org/source/openSUSE:12.2/pwdutils/pwdutils-%{version}.tar.bz2 #Source: http://www.kernel.org/pub/linux/utils/net/NIS/%{name}-%{version}.tar.bz2 Source1: pwdutils-pam-useradd Source2: pwdutils-pam-passwd Source3: pwdutils-pam-shadow Patch0: pwdutils-2.6.95-allow-devnull.patch Patch1: pwdutils-2.6.95-adduser-defaultgroup.patch Patch2: pwdutils-3.2.19-selinux-2.2.patch Patch3: pwdutils-3.2.19-glibc-2.19.patch License: GPL ## AUTOBUILDREQ-BEGIN BuildRequires: glibc-devel BuildRequires: libaudit-devel BuildRequires: libbioapi-devel BuildRequires: libe2fs-devel BuildRequires: libffi-devel BuildRequires: libgmp-devel BuildRequires: libgnutls-devel BuildRequires: libkeyutils-devel BuildRequires: libkrb5-devel BuildRequires: libnettle-devel BuildRequires: libnscd-devel %if "%{stage1}" != "1" BuildRequires: libopenldap-devel %endif BuildRequires: libopenslp-devel BuildRequires: libopenssl-devel BuildRequires: libp11-kit-devel BuildRequires: libpam-devel %if "%{stage1}" != "1" BuildRequires: libsasl-devel BuildRequires: libselinux-devel %endif BuildRequires: libstdc++6-devel BuildRequires: libtasn1-devel BuildRequires: libtirpc-devel BuildRequires: libz-devel BuildRequires: trousers-devel ## AUTOBUILDREQ-END BuildRequires: libnscd-devel BuildRequires: gettext-devel Requires(post):setup >= 1.1.13 Requires(post):shadow-common Requires(post):/bin/chmod Requires(post):/bin/chgrp Requires(post):pam Requires: cracklib-dicts >= 2.7 Conflicts: shadow BuildRoot: %{_tmppath}/%{name}-%{version}-root %description pwdutils is a collection of utilities to manage the passwd and shadow user information. The difference to the shadow suite is that these utilities can also modify the information stored in NIS, NIS+, or LDAP. PAM is used for user authentication and changing the pasword. It contains passwd, chage, chfn, chsh, and a daemon for changing the password on a remote machine over a secure SSL connection. The daemon also uses PAM so that it can change passwords independent of where they are stored. %package extras Group: System/Tools Summary: Extra pwdutils tools replaced now by util-linux Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release} %description extras Extra pwdutils tools replaced now by util-linux. %prep %setup -q %patch0 -p1 %patch1 -p1 %patch2 -p1 %patch3 -p1 %build # LDFLAGS="-ldl -lcrypto -ltirpc" \ %configure \ LDFLAGS="-ltirpc" \ %if "%{stage1}" != "1" --with-ldap-conf-file=%{_sysconfdir}/ldap.conf \ --with-ldap-secret-file=%{_sysconfdir}/ldap.secret %else --disable-ldap %endif %make %install [ "%{buildroot}" != / ] && rm -rf %{buildroot} %makeinstall initddir=%{_initrddir} cp %{S:1} %{buildroot}%{_sysconfdir}/pam.d/useradd cp %{S:1} %{buildroot}%{_sysconfdir}/pam.d/chage cp %{S:1} %{buildroot}%{_sysconfdir}/pam.d/chfn cp %{S:1} %{buildroot}%{_sysconfdir}/pam.d/chsh cp %{S:2} %{buildroot}%{_sysconfdir}/pam.d/passwd cp %{S:2} %{buildroot}%{_sysconfdir}/pam.d/rpasswd cp %{S:3} %{buildroot}%{_sysconfdir}/pam.d/shadow rm -f %{buildroot}%{_sysconfdir}/default/passwd rm -f %{buildroot}%{_sysconfdir}/login.defs rm -f %{buildroot}%{_mandir}/man5/login.defs.* %{find_lang} %{name} %clean [ "%{buildroot}" != / ] && rm -rf %{buildroot} %post groupadd shadow -g %{shadowgroupid} 2>/dev/null || : if [ $1 -ge 1 ]; then # upgrade passwords to shadow system # for a new install or an upgrade /usr/sbin/pwconv chmod 0640 /etc/shadow chgrp shadow /etc/shadow fi exit 0 %files -f %{name}.lang %defattr(-,root,root) %{_sysconfdir}/default/useradd %{_sysconfdir}/pwdutils/logging %{_initrddir}/rpasswdd %{_sysconfdir}/rpasswd.conf %{_sysconfdir}/pam.d/chage %{_sysconfdir}/pam.d/passwd %{_sysconfdir}/pam.d/rpasswd %{_sysconfdir}/pam.d/shadow %{_sysconfdir}/pam.d/useradd %{_bindir}/chage %{_bindir}/expiry %{_bindir}/gpasswd %{_bindir}/newgrp %attr (4755,root,shadow) %{_bindir}/passwd %{_bindir}/rpasswd %{_bindir}/sg %{_sbindir}/* %{_libdir}/pwdutils/* %{_mandir}/man1/chage.1* %{_mandir}/man1/expiry.1* %{_mandir}/man1/gpasswd.1* %{_mandir}/man1/newgrp.1* %{_mandir}/man1/passwd.1* %{_mandir}/man1/rpasswd.1* %{_mandir}/man1/sg.1* %{_mandir}/man5/* %{_mandir}/man8/* %doc AUTHORS COPYING #%doc ABOUT-NLS ChangeLog NEWS README THANKS TODO %files extras %defattr(-,root,root) %{_sysconfdir}/pam.d/chfn %{_sysconfdir}/pam.d/chsh %{_bindir}/chfn %{_bindir}/chsh %{_mandir}/man1/chfn.1* %{_mandir}/man1/chsh.1* %changelog * Sat Aug 09 2014 Silvan Calarco 3.2.19-3mamba - also chfn man needs to be moved to extra package * Sat Aug 02 2014 Silvan Calarco 3.2.19-2mamba - move chsh and chfn to extra package because replaced by util-linux implementation since 2.25 * Wed Apr 16 2014 Silvan Calarco 3.2.19-1mamba - update to 3.2.19 * Wed Apr 16 2014 Silvan Calarco 3.2.13-2mamba - added require(post) for pam * Fri Jun 17 2011 Automatic Build System 3.2.13-1mamba - automatic update by autodist * Mon Jul 19 2010 Silvan Calarco 3.2.11-2mamba - launch pwconv on install/upgrade to update/create shadow file * Sun Jul 11 2010 Automatic Build System 3.2.11-1mamba - automatic update by autodist * Mon Jun 28 2010 Silvan Calarco 3.2.10-2mamba - added prereq for shadow-common * Tue Jun 22 2010 Automatic Build System 3.2.10-1mamba - automatic update by autodist * Sat Mar 13 2010 Silvan Calarco 3.2.5-3mamba - shadow: set as conflict instead of obsolete * Fri Feb 05 2010 Silvan Calarco 3.2.5-2mamba - ... add a changelog entry * Fri Jul 24 2009 Automatic Build System 3.2.5-1mamba - automatic update by autodist * Mon Jun 08 2009 Silvan Calarco 3.2.2-2mamba - fix init.d dir (use %initrddir) * Sat Jan 10 2009 Silvan Calarco 3.2.2-1mamba - automatic update by autodist * Fri Feb 15 2008 Silvan Calarco 3.1.3-4mamba - rebuilt againts libopenldap 2.4 * Tue Jan 15 2008 Silvan Calarco 3.1.3-3mamba - rebuilt * Sun Jun 24 2007 Silvan Calarco 3.1.3-2mamba - obsolete use of pam_stack, use include instead * Fri May 25 2007 Silvan Calarco 3.1.3-1mamba - update to 3.1.3 - added prereq for setup package * Fri May 26 2006 Davide Madrisan 3.0.7-1qilnx - update to version 3.0.7 by autospec - fixed permissions for passwd (qibug#174) * Fri Nov 11 2005 Stefano Cotta Ramusino 3.0-2qilnx - add cracklib-dicts requirement * Mon Nov 07 2005 Stefano Cotta Ramusino 3.0-1qilnx - update to version 3.0 by autospec * Tue Apr 26 2005 Silvan Calarco 2.6.95-7qilnx - add shadow group if missing * Tue Apr 26 2005 Silvan Calarco 2.6.95-7qilnx - use default group number 100 for new added users * Mon Mar 07 2005 Silvan Calarco 2.6.95-6qilnx - allow /dev/null as a home directory * Fri Mar 04 2005 Silvan Calarco 2.6.95-5qilnx - execute pwconv on install/upgrade to create /etc/shadow file * Fri Mar 04 2005 Silvan Calarco 2.6.95-4qilnx - exclude file /etc/default/passwd with comes from pam_unix2.so in pam pkg * Fri Mar 04 2005 Silvan Calarco 2.6.95-3qilnx - don't provide shadow - require shadow-common * Thu Mar 03 2005 Silvan Calarco 2.6.95-2qilnx - exclude /etc/login.defs which is already in the shadow-common package * Fri Feb 25 2005 Silvan Calarco 2.6.95-1qilnx - update to version 2.6.95 by autospec * Thu Oct 28 2004 Silvan Calarco 2.6.4-2qilnx - removed libdb.so dependency * Tue Oct 26 2004 Silvan Calarco 2.6.4-1qilnx - package created by autospec