]> git.pld-linux.org Git - packages/pwdutils.git/blame - pwdutils.spec
remove /etc/skel/etc dir, home_etc is unmaintained and current standard is xdg
[packages/pwdutils.git] / pwdutils.spec
CommitLineData
2d0a5d72
PS
1#
2# Conditional build:
e0b43f18 3%bcond_without audit # don't build audit log plugin
b439f0c4 4%bcond_without ldap # build without LDAP support
4da5d1c6 5%bcond_without selinux # build without SELinux support
c8ad241f 6%bcond_with bioapi # with BioAPI support in passwd
27d570ab 7%bcond_with gnutls # use GnuTLS instead of OpenSSL
2d0a5d72 8#
6a644dc5 9Summary: Utilities to manage the passwd and shadow user information
a18ac25c 10Summary(pl.UTF-8): Narzędzia do zarządzania informacjami o użytkownikach z passwd i shadow
5fe84642 11Name: pwdutils
b98fb9c9 12Version: 3.2.19
e6eaf09b 13Release: 1
67de6519 14License: GPL v2
97d6c528 15Group: Base
5bbc0db8
AM
16#Source0: ftp://ftp.kernel.org/pub/linux/utils/net/NIS/%{name}-%{version}.tar.bz2
17Source0: http://www.linux-nis.org/download/pwdutils/%{name}-%{version}.tar.bz2
b98fb9c9 18# Source0-md5: 25a77a0ab376eacf24ad5eab7af4cdce
8ca1fd06 19Source1: %{name}.useradd
2671fa95 20Source2: %{name}.rpasswdd.init
8ca1fd06
AM
21Source3: %{name}.login.defs
22Source4: chage.pamd
23Source5: chfn.pamd
24Source6: chsh.pamd
25Source7: passwd.pamd
26Source8: useradd.pamd
534b5bbd 27Source9: userdb.pamd
badc953f 28Source10: rpasswd.pamd
7cad659a 29Patch0: %{name}-f-option.patch
e0b43f18
JB
30Patch1: %{name}-no_bash.patch
31Patch2: %{name}-silent_crontab.patch
cc9dfdec 32Patch3: %{name}-pl.po-update.patch
b98fb9c9 33Patch4: %{name}-selinux.patch
3fdc98c4 34Patch5: %{name}-am.patch
034d3cb4 35Patch6: %{name}-libc-lock.patch
f82dc29f 36Patch7: %{name}-format-security.patch
aeacfcd4 37URL: http://www.thkukuk.de/pam/pwdutils/
e0b43f18 38%{?with_audit:BuildRequires: audit-libs-devel}
5fe84642 39BuildRequires: autoconf
e6eaf09b 40BuildRequires: automake >= 1:1.9
c8ad241f 41%{?with_bioapi:BuildRequires: bioapi-devel}
9ac28af5 42BuildRequires: gcc >= 5:3.2
5fe84642 43BuildRequires: gettext-devel
27d570ab 44%{?with_gnutls:BuildRequires: gnutls-devel >= 1.0.0}
67de6519 45BuildRequires: libnscd-devel
4da5d1c6 46%{?with_selinux:BuildRequires: libselinux-devel}
7f892c42 47BuildRequires: libtool
8458c410 48BuildRequires: libxcrypt-devel
915ec188 49%{?with_ldap:BuildRequires: openldap-devel >= 2.4.6}
aeacfcd4 50BuildRequires: openslp-devel
37410059 51%{!?with_gnutls:BuildRequires: openssl-devel >= 0.9.7d}
6a644dc5 52BuildRequires: pam-devel
37410059 53BuildRequires: rpmbuild(macros) >= 1.268
f3804003 54BuildRequires: sed >= 4.0
fbc4a361 55Requires: pam >= 0.99.7.1
c95ca6c9
AM
56Provides: shadow = 2:%{version}-%{release}
57Provides: shadow-extras = 2:%{version}-%{release}
e7523ef5 58Obsoletes: shadow
f3804003 59Obsoletes: shadow-extras
9d62b365 60Obsoletes: shadow-utils
e7523ef5 61Conflicts: util-linux < 2.12-10
5fe84642
AM
62BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
63
9feef33b
JB
64# for pam module in /%{_lib}/security
65%define _libdir /%{_lib}
66
5fe84642 67%description
6a644dc5
JB
68pwdutils is a collection of utilities to manage the passwd and shadow
69user information. The difference to the shadow suite is that these
70utilities can also modify the information stored in NIS, NIS+, or
71LDAP. PAM is used for user authentication and changing the pasword. It
72contains passwd, chage, chfn, chsh, and a daemon for changing the
73password on a remote machine over a secure SSL connection. The daemon
74also uses PAM so that it can change passwords independent of where
da114143 75they are stored.
6a644dc5 76
cdfe8b28
JR
77%description -l pl.UTF-8
78pwdutils to zestaw narzędzi do zarządzania informacjami o
79użytkownikach z passwd i shadow. Różnica w stosunku do pakietu shadow
80polega na tym, że te narzędzia mogą także modyfikować informacje
81zapisane w bazie NIS, NIS+ lub LDAP. PAM jest używany do
82uwierzytelniania użytkowników i zmiany haseł. Zestaw zawiera passwd,
83chage, chfn, chsh oraz demona do zmiany hasła na zdalnej maszynie po
84bezpiecznym połączeniu SSL. Demon także używa PAM, więc można zmieniać
85hasła niezależnie od tego, gdzie są przechowywane.
5fe84642 86
e0b43f18
JB
87%package log-audit
88Summary: audit log plugin for pwdutils
a18ac25c 89Summary(pl.UTF-8): Wtyczka logująca audit dla pwdutils
e0b43f18
JB
90Group: Libraries
91Requires: %{name} = %{version}-%{release}
92
93%description log-audit
94audit log plugin for pwdutils.
95
cdfe8b28
JR
96%description log-audit -l pl.UTF-8
97Wtyczka logująca audit dla pwdutils.
e0b43f18 98
48420078
JR
99%package -n rpasswd
100Summary: Remote password update client
a18ac25c 101Summary(pl.UTF-8): Klient do zdalnego uaktualniania haseł
48420078
JR
102Group: Applications/System
103
104%description -n rpasswd
105rpasswd changes passwords for user accounts on a remote server over a
106secure SSL connection. A normal user may only change the password for
107their own account, if the user knows the password of the administrator
8458c410 108account (in the moment this is the root password on the server), he
109may change the password for any account if he calls rpasswd with the
110-a option.
48420078 111
cdfe8b28
JR
112%description -n rpasswd -l pl.UTF-8
113rpasswd pozwala zmieniać hasła użytkowników na zdalnym serwerze przy
114użyciu bezpiecznego połączenia SSL. Zwykły użytkownik może zmienić
115jedynie swoje hasło, a jeśli zna hasło administratora (obecnie jest to
116hasło roota na serwerze), może zmienić hasło dla dowolnego konta
117wywołując rpasswd z opcją -a.
48420078 118
2671fa95
AM
119%package -n rpasswdd
120Summary: Remote password update daemon
a18ac25c 121Summary(pl.UTF-8): Demon do zdalnego uaktualniania haseł
2671fa95 122Group: Applications/System
90b18a39 123Requires(post,preun): /sbin/chkconfig
37410059 124Requires: rc-scripts
2671fa95
AM
125
126%description -n rpasswdd
127rpasswdd is a daemon that lets users change their passwords in the
128presence of a directory service like NIS, NIS+ or LDAP over a secure
129SSL connection. rpasswdd behaves like the normal passwd(1) program and
01eb9107 130uses PAM for authentication and changing the password, so it can be
c02236cd 131configured very flexible for the local requirements.
2671fa95 132
cdfe8b28
JR
133%description -n rpasswdd -l pl.UTF-8
134rpasswdd to demon pozwalający użytkownikom zmieniać hasła w obecności
135usług katalogowych takich jak NIS, NIS+ czy LDAP po bezpiecznym
136połączeniu SSL. rpasswdd zachowuje się tak, jak normalny program
137passwd(1) i używam PAM do uwierzytelniania i zmiany haseł, więc może
138być bardzo elastycznie konfigurowany dla lokalnych wymagań.
01eb9107 139
9feef33b
JB
140%package -n pam-pam_rpasswd
141Summary: pam_rpasswd - PAM module to change remote password
a18ac25c 142Summary(pl.UTF-8): pam_rpasswd - moduł PAM do zdalnej zmiany hasła
9feef33b 143Group: Base
48420078
JR
144# rpasswd.conf is in rpasswd
145Requires: rpasswd = %{version}-%{release}
9feef33b
JB
146
147%description -n pam-pam_rpasswd
148The pam_rpasswd PAM module is for changing the password of user
149accounts on a remote server over a secure SSL connection. It only
150provides functionality for one PAM management group: password
151changing.
152
cdfe8b28
JR
153%description -n pam-pam_rpasswd -l pl.UTF-8
154Moduł PAM pam_rpasswd służy do zmiany haseł dla kont użytkowników na
155zdalnym serwerze po bezpiecznym połączeniu SSL. Udostępnia
156funkcjonalność tylko dla jednej grupy zarządzania PAM: zmiany haseł.
9feef33b 157
5fe84642
AM
158%prep
159%setup -q
7cad659a 160%patch0 -p1
b439f0c4 161%patch1 -p1
db28862c 162%patch2 -p1
cc9dfdec 163%patch3 -p1
b98fb9c9 164%patch4 -p1
3fdc98c4 165%patch5 -p1
034d3cb4 166%patch6 -p1
f82dc29f 167%patch7 -p1
cc9dfdec
JB
168
169%{__rm} po/stamp-po
8458c410 170
5c20f24f 171%build
5fe84642 172%{__gettextize}
7c16c049 173%{__libtoolize}
5ba998e4 174%{__aclocal} -I m4
5fe84642 175%{__autoconf}
b869fe96 176%{__autoheader}
5fe84642
AM
177%{__automake}
178%configure \
c8ad241f
JB
179 %{?with_bioapi:CPPFLAGS="-I/usr/include/bioapi"} \
180 %{!?with_bioapi:ac_cv_header_bioapi_h=no ac_cv_lib_bioapi100_BioAPI_Init=no} \
e0b43f18 181 %{?with_audit:--enable-audit-plugin} \
27d570ab 182 %{!?with_gnutls:--disable-gnutls} \
e0b43f18
JB
183 --%{?with_ldap:en}%{!?with_ldap:dis}able-ldap \
184 --enable-nls \
aeacfcd4 185 --enable-pam_rpasswd \
4da5d1c6 186 --%{?with_selinux:en}%{!?with_selinux:dis}able-selinux \
aeacfcd4 187 --enable-slp \
5fe84642
AM
188 --disable-rpath
189%{__make}
190
191%install
192rm -rf $RPM_BUILD_ROOT
467ecff1 193install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,pwdutils,security,skel/{etc,tmp}}
5fe84642
AM
194
195%{__make} install \
196 DESTDIR=$RPM_BUILD_ROOT
197
67de6519 198mv -f $RPM_BUILD_ROOT%{_sbindir}/*.local $RPM_BUILD_ROOT%{_sysconfdir}/pwdutils
2671fa95
AM
199install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/default/useradd
200install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/rpasswdd
201install %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/login.defs
8ca1fd06
AM
202
203install %{SOURCE4} $RPM_BUILD_ROOT/etc/pam.d/chage
204install %{SOURCE5} $RPM_BUILD_ROOT/etc/pam.d/chfn
205install %{SOURCE6} $RPM_BUILD_ROOT/etc/pam.d/chsh
206install %{SOURCE7} $RPM_BUILD_ROOT/etc/pam.d/passwd
207install %{SOURCE8} $RPM_BUILD_ROOT/etc/pam.d/useradd
534b5bbd 208install %{SOURCE9} $RPM_BUILD_ROOT/etc/pam.d/shadow
badc953f 209install %{SOURCE10} $RPM_BUILD_ROOT/etc/pam.d/rpasswd
8ca1fd06 210
57999f04
JB
211%{__rm} $RPM_BUILD_ROOT%{_libdir}/pwdutils/*.{la,a}
212%{__rm} $RPM_BUILD_ROOT/%{_lib}/security/pam_*.la
213%{__rm} $RPM_BUILD_ROOT%{_sysconfdir}/init.d/rpasswdd
67de6519 214
b9e495eb
JB
215:> $RPM_BUILD_ROOT%{_sysconfdir}/shadow
216:> $RPM_BUILD_ROOT/etc/security/chfn.allow
217:> $RPM_BUILD_ROOT/etc/security/chsh.allow
801fabc9 218
5fe84642
AM
219%find_lang %{name}
220
221%clean
222rm -rf $RPM_BUILD_ROOT
223
224%post
6118303e 225if [ ! -f %{_sysconfdir}/shadow ]; then
5fe84642
AM
226 %{_sbindir}/pwconv
227fi
228
2671fa95
AM
229%post -n rpasswdd
230/sbin/chkconfig --add rpasswdd
37410059 231%service rpasswdd restart "rpasswdd daemon"
2671fa95
AM
232
233%preun -n rpasswdd
234if [ "$1" = "0" ]; then
37410059 235 %service rpasswdd stop
53d92fc1 236 /sbin/chkconfig --del rpasswdd
2671fa95
AM
237fi
238
5fe84642
AM
239%files -f %{name}.lang
240%defattr(644,root,root,755)
dd06a689 241%doc AUTHORS ChangeLog NEWS README THANKS TODO
5c20f24f 242%attr(600,root,root) %config(noreplace) %verify(not md5 mtime size) %ghost %{_sysconfdir}/shadow
5c20f24f 243%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/default/*
8ca1fd06 244%attr(750,root,root) %dir %{_sysconfdir}/%{name}
5c20f24f 245%attr(750,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/*.local
95539a65 246%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/logging
5c20f24f
JB
247%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/chage
248%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/chfn
249%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/chsh
250%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/passwd
251%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/useradd
252%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/shadow
7f892c42 253%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/login.defs
b9e495eb
JB
254%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/security/chfn.allow
255%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/security/chsh.allow
5fe84642 256%dir /etc/skel
97d6c528 257%dir %config(missingok) %attr(700,root,root) /etc/skel/tmp
8ca1fd06
AM
258%attr(755,root,root) %{_bindir}/chage
259%attr(4755,root,root) %{_bindir}/chfn
260%attr(4755,root,root) %{_bindir}/chsh
261%attr(4755,root,root) %{_bindir}/expiry
b869fe96 262%attr(4755,root,root) %{_bindir}/gpasswd
8a9684a4 263%attr(4755,root,root) %{_bindir}/newgrp
5fe84642 264%attr(4755,root,root) %{_bindir}/passwd
8a9684a4 265%attr(4755,root,root) %{_bindir}/sg
8ca1fd06
AM
266%attr(755,root,root) %{_sbindir}/chpasswd
267%attr(755,root,root) %{_sbindir}/groupadd
268%attr(755,root,root) %{_sbindir}/groupdel
b869fe96 269%attr(755,root,root) %{_sbindir}/groupmod
c5678d54 270%attr(755,root,root) %{_sbindir}/grpconv
c95ca6c9 271%attr(755,root,root) %{_sbindir}/grpck
534b5bbd 272%attr(755,root,root) %{_sbindir}/grpunconv
c5678d54 273%attr(755,root,root) %{_sbindir}/pwconv
c95ca6c9 274%attr(755,root,root) %{_sbindir}/pwck
c5678d54 275%attr(755,root,root) %{_sbindir}/pwunconv
8ca1fd06
AM
276%attr(755,root,root) %{_sbindir}/useradd
277%attr(755,root,root) %{_sbindir}/userdel
b869fe96 278%attr(755,root,root) %{_sbindir}/usermod
ba407186
JB
279%attr(755,root,root) %{_sbindir}/vigr
280%attr(755,root,root) %{_sbindir}/vipw
67de6519
JB
281%dir %{_libdir}/pwdutils
282%attr(755,root,root) %{_libdir}/pwdutils/liblog_syslog.so*
7c16c049
JB
283%{_mandir}/man1/chage.1*
284%{_mandir}/man1/chfn.1*
285%{_mandir}/man1/chsh.1*
286%{_mandir}/man1/expiry.1*
287%{_mandir}/man1/gpasswd.1*
288%{_mandir}/man1/newgrp.1*
289%{_mandir}/man1/passwd.1*
290%{_mandir}/man1/sg.1*
291%{_mandir}/man5/login.defs.5*
292%{_mandir}/man8/chpasswd.8*
293%{_mandir}/man8/groupadd.8*
294%{_mandir}/man8/groupdel.8*
295%{_mandir}/man8/groupmod.8*
296%{_mandir}/man8/grpck.8*
297%{_mandir}/man8/grpconv.8*
298%{_mandir}/man8/grpunconv.8*
299%{_mandir}/man8/pwck.8*
300%{_mandir}/man8/pwconv.8*
301%{_mandir}/man8/pwunconv.8*
302%{_mandir}/man8/useradd.8*
303%{_mandir}/man8/userdel.8*
304%{_mandir}/man8/usermod.8*
305%{_mandir}/man8/vigr.8*
306%{_mandir}/man8/vipw.8*
2671fa95 307
e0b43f18
JB
308%if %{with audit}
309%files log-audit
310%defattr(644,root,root,755)
311%attr(755,root,root) %{_libdir}/pwdutils/liblog_audit.so*
312%endif
313
48420078
JR
314%files -n rpasswd
315%defattr(644,root,root,755)
316%attr(755,root,root) %{_bindir}/rpasswd
6118303e 317%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/rpasswd.conf
48420078
JR
318%{_mandir}/man1/rpasswd.1*
319%{_mandir}/man5/rpasswd.conf.5*
320
2671fa95
AM
321%files -n rpasswdd
322%defattr(644,root,root,755)
323%attr(755,root,root) %{_sbindir}/rpasswdd
324%attr(754,root,root) /etc/rc.d/init.d/rpasswdd
5c20f24f
JB
325%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/rpasswd
326%{_mandir}/man8/rpasswdd.8*
9feef33b
JB
327
328%files -n pam-pam_rpasswd
329%defattr(644,root,root,755)
cc9dfdec 330%attr(755,root,root) /%{_lib}/security/pam_rpasswd.so
9feef33b 331%{_mandir}/man8/pam_rpasswd.8*
This page took 0.125042 seconds and 4 git commands to generate.