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