]> git.pld-linux.org Git - packages/cyrus-sasl.git/blob - cyrus-sasl.spec
5cbf6ddb63082deaff3b4bc7429c6cf6c8d6fb1b
[packages/cyrus-sasl.git] / cyrus-sasl.spec
1 #
2 # TODO:
3 # - add ldap plugin from openldap sources
4 #
5 # Conditional build:
6 # _with_srp             - build srp pluggin
7 # _without_myslq        - don't build mysql pluggin
8 # _without_ldap         - disable LDAP support for sasluthd
9 #
10 Summary:        The SASL library API for the Cyrus mail system
11 Summary(pl):    Biblioteka Cyrus SASL
12 Summary(pt_BR): Implementação da API SASL
13 Summary(ru):    âÉÂÌÉÏÔÅËÁ Cyrus SASL
14 Summary(uk):    â¦Â̦ÏÔÅËÁ Cyrus SASL
15 Name:           cyrus-sasl
16 Version:        2.1.13
17 Release:        0.2
18 License:        distributable
19 Group:          Libraries
20 Source0:        ftp://ftp.andrew.cmu.edu/pub/cyrus/%{name}-%{version}.tar.gz
21 # Source0-md5: 1114d59d970791932e96de8557472672
22 Source1:        saslauthd.init
23 Source2:        saslauthd.sysconfig
24 Source3:        %{name}.pam
25 Patch0:         %{name}-configdir.patch
26 Patch1:         %{name}-nolibs.patch
27 Patch2:         %{name}-lt14d.patch
28 Patch3:         %{name}-do_dlopen.patch
29 URL:            http://asg.web.cmu.edu/sasl/
30 BuildRequires:  autoconf
31 BuildRequires:  automake
32 BuildRequires:  db-devel
33 BuildRequires:  ed
34 BuildRequires:  libtool >= 1.4
35 %{!?_without_mysql:BuildRequires: mysql-devel}
36 %{!?_without_ldap:BuildRequires: openldap-devel}
37 BuildRequires:  openssl-devel >= 0.9.7
38 BuildRequires:  pam-devel
39 Requires(post): /sbin/ldconfig
40 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41
42 %define         _sysconfdir     /etc/sasl
43
44 %description
45 This is an implementation of the SASL API, useful for adding
46 authentication, authorization, and security to network protocols. The
47 SASL protocol itself is documented in rfc2222; the API standard is a
48 work in progress.
49
50 %description -l pl
51 Pakiet cyrus-sasl zawiera implementacjê biblioteki API SASL dla
52 systemu poczty elektronicznej Cyrusa. Biblioteka ta jest przydatna
53 tak¿e do dodawania uwierzytelniania, autoryzacji oraz zwiêkszania
54 bezpieczeñstwa protoko³ów sieciowych. Sam protokó³ SASL jest opisany w
55 RFC 2222; standaryzacja API jest w toku.
56
57 %description -l pt_BR
58 Esta é uma implementação da API SASL, útil para acrescentar
59 autenticação, autorização e seguança (criptografia) para protocolos de
60 rede. O protocolo SASL está documentado na RFC 2222. A API "padrão"
61 ainda está em desenvolvimento.
62
63 %description -l ru
64 ðÁËÅÔ cyrus-sasl ÓÏÄÅÒÖÉÔ ÒÅÁÌÉÚÁÃÉÀ Cyrus SASL. SASL - ÜÔÏ Simple
65 Authentication and Security Layer, ÍÅÔÏÄ ÄÌÑ ÄÏÂÁ×ÌÅÎÉÑ ÐÏÄÄÅÒÖËÉ
66 ÁÕÔÅÎÔÉËÁÃÉÉ Ë ÐÒÏÔÏËÏÌÁÍ, ÏÓÎÏ×ÁÎÎÙÍ ÎÁ ÓÏÅÄÉÎÅÎÉÑÈ.
67
68 %description -l uk
69 ðÁËÅÔ cyrus-sasl Í¦ÓÔÉÔØ ÒÅÁ̦ÚÁæÀ Cyrus SASL. SASL - ÃÅ Simple
70 Authentication and Security Layer, ÍÅÔÏÄ ÄÌÑ ÄÏÄÁÎÎѠЦÄÔÒÉÍËÉ
71 ÁÕÔÅÎÔÉËÁ槠ÄÏ ÐÒÏÔÏËÏ̦×, ÂÁÚÏ×ÁÎÉÈ ÎÁ Ú'¤ÄÎÁÎÎÑÈ.
72
73 %package devel
74 Summary:        Header files and documentation for cyrus-sasl
75 Summary(pl):    Pliki nag³ówkowe i dokumentacja dla cyrus-sasl
76 Summary(pt_BR): Exemplos e arquivos para desenvolvimento com SASL
77 Summary(ru):    æÁÊÌÙ ÄÌÑ ÐÒÏÇÒÁÍÍÉÒÏ×ÁÎÉÑ Ó ÂÉÂÌÉÏÔÅËÏÊ Cyrus SASL
78 Summary(ru):    æÁÊÌÉ ÄÌÑ ÐÒÏÇÒÁÍÕ×ÁÎÎѠڠ¦Â̦ÏÔÅËÏÀ Cyrus SASL
79 Group:          Development/Libraries
80 Requires:       %{name} = %{version}
81
82 %description devel
83 This includes the header files and documentation needed to develop
84 applications which use SASL.
85
86 %description devel -l pl
87 Pliki nag³ówkowe i dokumentacja dla cyrus-sasl.
88
89 %description devel -l pt_BR
90 Este pacote inclui os arquivos de cabeçalho e documentação necessários
91 para desenvolver aplicativos que usem SASL.
92
93 %description devel -l ru
94 èÅÄÅÒÙ É ÂÉÂÌÉÏÔÅËÉ, ÎÅÏÂÈÏÄÉÍÙÅ ÄÌÑ ÒÁÚÒÁÂÏÔËÉ ÐÒÉÌÏÖÅÎÉÊ,
95 ÉÓÐÏÌØÚÕÀÝÉÈ Cyrus SASL.
96
97 %description devel -l uk
98 èÅÄÅÒÉ ÔÁ Â¦Â̦ÏÔÅËÉ, ÎÅÏÂȦÄΦ ÄÌÑ ÒÏÚÒÏÂËÉ ÐÒÏÇÒÁÍ, ÝÏ
99 ×ÉËÏÒÉÓÔÏ×ÕÀÔØ Cyrus SASL.
100
101 %package static
102 Summary:        Static cyrus-sasl libraries
103 Summary(pl):    Statyczne biblioteki cyrus-sasl
104 Summary(ru):    óÔÁÔÉÞÅÓËÉÅ ÂÉÂÌÉÏÔÅËÉ Cyrus SASL
105 Summary(uk):    óÔÁÔÉÞΦ Â¦Â̦ÏÔÅËÉ Cyrus SASL
106 Group:          Development/Libraries
107 Requires:       %{name}-devel = %{version}
108
109 %description static
110 Static cyrus-sasl libraries.
111
112 %description static -l pl
113 Statyczne biblioteki cyrus-sasl.
114
115 %description static -l ru
116 óÔÁÔÉÞÅÓËÉÅ ÂÉÂÌÉÏÔÅËÉ, ÎÅÏÂÈÏÄÉÍÙÅ ÄÌÑ ÒÁÚÒÁÂÏÔËÉ ÐÒÉÌÏÖÅÎÉÊ,
117 ÉÓÐÏÌØÚÕÀÝÉÈ Cyrus SASL.
118
119 %description static -l uk
120 óÔÁÔÉÞΦ Â¦Â̦ÏÔÅËÉ, ÎÅÏÂȦÄΦ ÄÌÑ ÒÏÚÒÏÂËÉ ÐÒÏÇÒÁÍ, ÝÏ ×ÉËÏÒÉÓÔÏ×ÕÀÔØ
121 Cyrus SASL.
122
123 %package cram-md5
124 Summary:        Cram-MD5 Cyrus SASL plugin
125 Summary(pl):    Wtyczka Cram-MD5 do Cyrus SASL
126 Summary(pt_BR): Mecanismo SASL CRAM-MD5
127 Group:          Libraries
128 Requires:       %{name} = %{version}
129
130 %description cram-md5
131 This plugin implements the SASL CRAM-MD5 mechanism. CRAM-MD5 is the
132 mandatory-to-implement authentication mechanism for a number of
133 protocols; it uses MD5 with a challenge/response system to
134 authenticate the user.
135
136 %description cram-md5 -l pl
137 Wtyczka dodaj±ca obs³ugê mechanizmu CRAM-MD5 do Cyrus SASL. CRAM-MD5
138 jest obowi±zkowym do zaimplementowania mechanizmem uwierzytelniania
139 dla wielu protoko³ów; do uwierzytelnienia u¿ytkownika u¿ywa MD5 wraz z
140 systemem challenge/response.
141
142 %description cram-md5 -l pt_BR
143 Este plugin implementa o mecanismo SASL CRAM-MD5. CRAM-MD5 é o
144 mecanismo de autenticação obrigatório de ser implementado para vários
145 protocolos: ele usa MD5 com um sistema de desafio/resposta para
146 autenticar o usuário.
147
148 %package digest-md5
149 Summary:        Digest-MD5 Cyrus SASL plugin
150 Summary(pl):    Wtyczka Digest-MD5 do Cyrus SASL
151 Summary(pt_BR): Mecanismo SASL DIGEST-MD5
152 Group:          Libraries
153 Requires:       %{name} = %{version}
154
155 %description digest-md5
156 This plugin implements the latest draft of the SASL DIGEST-MD5
157 mechanism. Although not yet finalized, this is likely to become the
158 new mandatory-to-implement authentication system in all new protocols.
159 It's based on the digest md5 authentication system designed for HTTP.
160
161 %description digest-md5 -l pl
162 Wtyczka dodaj±ca najnowsz± wersjê mechanizmu DIGEST-MD5 do Cyrus SASL.
163 Pomimo tego, ¿e nie jest jeszcze ukoñczony, najprawdopodobniej stanie
164 siê obowi±zkowym do zaimplementowania systemem uwierzytelniania we
165 wszystkich nowych protoko³ach. Bazuje na systemie uwierzytelniania
166 Digest-MD5 zaprojektowanym dla HTTP.
167
168 %description digest-md5 -l pt_BR
169 Este plugin implementa a última versão da especificação do mecanismo
170 SASL DIGEST-MD5. Embora ainda não esteja finalizado, DIGEST-MD5
171 provavelmente será o novo sistema de autenticação obrigatório para
172 protocolos novos. Ele é baseado na autenticação md5 digest
173 desenvolvida para HTTP.
174
175 %package plain
176 Summary:        Plain Cyrus SASL plugin
177 Summary(pl):    Wtyczka plain do Cyrus SASL
178 Summary(pt_BR): Mecanismo SASL PLAIN
179 Group:          Libraries
180 Requires:       %{name} = %{version}
181
182 %description plain
183 This plugin implements the SASL PLAIN mechanism. Although insecure,
184 PLAIN is useful for transitioning to new security mechanisms, as this
185 is the only mechanism which gives the server a copy of the user's
186 password.
187
188 %description plain -l pl
189 Wtyczka dodaj±ca obs³ugê mechanizmu PLAIN do Cyrus SASL. Pomimo tego,
190 ¿e nie jest bezpieczny, PLAIN jest przydatny przy przechodzeniu na
191 nowe mechanizmu bezpieczeñstwa, jako ¿e jest to jedyny mechanizm,
192 który udostêpnia serwerowi kopiê has³a u¿ytkownika.
193
194 %description plain -l pt_BR
195 Este plugin implementa o mecanismo SASL PLAIN. Embora inseguro, este
196 mecanismo é útil durante transições para novos mecanismos de
197 segurança, pois é o único esquema que fornece uma cópia da senha do
198 usuário para o servidor.
199
200 %package anonymous
201 Summary:        Anonymous Cyrus SASL plugin
202 Summary(pl):    Wtyczka anonymous do Cyrus SASL
203 Summary(pt_BR): Mecanismo SASL ANONYMOUS
204 Group:          Libraries
205 Requires:       %{name} = %{version}
206
207 %description anonymous
208 This plugin implements the SASL ANONYMOUS mechanism, used for
209 anonymous authentication.
210
211 %description anonymous -l pl
212 Wtyczka dodaj±ca obs³ugê mechanizmu ANONYMOUS do Cyrus SASL. S³u¿y do
213 anonimowego uwierzytelniania.
214
215 %description anonymous -l pt_BR
216 Este plugin implementa o mecanismo SASL ANONYMOUS, usado para
217 autenticação anônima.
218
219 %package login
220 Summary:        Unsupported Login Cyrus SASL plugin
221 Summary(pl):    Nie wspierana wtyczka Login do Cyrus SASL
222 Group:          Libraries
223 Requires:       %{name} = %{version}
224
225 %description login
226 Unsupported LOGIN Cyrus SASL plugin.
227
228 %description login -l pl
229 Wtyczka dodaj±ca obs³ugê nie wspieranego mechanizmu LOGIN do Cyrus
230 SASL.
231
232 %package srp
233 Summary:        SRP Cyrus SASL plugin
234 Summary(pl):    Wtyczka SRP do Cyrus SASL
235 Summary(pt_BR): Mecanismo SASL SRP
236 Group:          Libraries
237 Requires:       %{name} = %{version}
238
239 %description srp
240 This plugin implements the SASL SRP mechanism, based on the Secure
241 Remote Password protocol. This mechanism performs mutual
242 authentication and can provide a security layer with replay detection,
243 integrity protection and/or condifentiality protection.
244
245 %description srp -l pl
246 Wtyczka dodaj±ca obs³ugê mechanizmu SRP do Cyrus SASL. Bazuje na
247 protokole Secure Remote Password. Ten mechanizm dokonuje wzajemnego
248 uwierzytelnienia i mo¿e dodawaæ warstwê bezpieczeñstwa z wykrywaniem
249 powtarzania, zabezpieczeniem integralno¶ci i/lub poufno¶ci.
250
251 %description srp -l pt_BR
252 Este plugin implementa o mecanismo SASL SRP, baseado no protocolo SRP
253 (Secure Remote Password). Este mecanismo oferece autenticação mútua
254 (do cliente e do servidor) e pode prover uma camada de segurança com
255 detecção de ataques de replay, garantia de integridade e/ou
256 confidencialidade.
257
258 %package otp
259 Summary:        OTP Cyrus SASL plugin
260 Summary(pl):    Wtyczka OTP do Cyrus SASL
261 Summary(pt_BR): Mecanismo SASL OTP
262 Group:          Libraries
263 Requires:       %{name} = %{version}
264
265 %description otp
266 This plugin implements the SASL OTP (One Time Password) mechanism.
267
268 %description otp -l pl
269 Wtyczka dodaj±ca obs³ugê mechanizmu OTP (has³a jednorazowe) do Cyrus
270 SASL.
271
272 %package x509
273 Summary:        x509 Cyrus SASL plugin
274 Summary(pl):    Wtyczka x509 do Cyrus SASL
275 Group:          Libraries
276 Requires:       %{name} = %{version}
277
278 %description x509
279 x509 Cyrus SASL plugin.
280
281 %description x509 -l pl
282 Wtyczka x509 do Cyrus SASL.
283
284 %package saslauthd
285 Summary:        Cyrus SASL authd
286 Summary(pl):    Demon authd do Cyrus SASL
287 Group:          Libraries
288 Requires(post,postun):  /sbin/chkconfig
289 Requires:       %{name} = %{version}
290
291 %description saslauthd
292 Cyrus SASL authd.
293
294 %description saslauthd -l pl
295 Demon authd do Cyrus SASL.
296
297 %package pwcheck
298 Summary:        Cyrus SASL pwcheck helper
299 Summary(pl):    Program pomocniczy pwcheck do Cyrus SASL
300 Group:          Libraries
301 Requires:       %{name} = %{version}
302
303 %description pwcheck
304 Cyrus SASL pwcheck helper.
305
306 %description pwcheck -l pl
307 Program pomocniczy pwcheck do Cyrus SASL.
308
309 %package sasldb
310 Summary:        Cyrus SASL sasldb plugin
311 Summary(pl):    Wtyczka sasldb do Cyrus SASL
312 Group:          Libraries
313 Requires:       %{name} = %{version}
314
315 %description sasldb
316 Cyrus SASL sasldb plugin.
317
318 %description sasldb -l pl
319 Wtyczka sasldb do Cyrus SASL.
320
321 %package mysql
322 Summary:        Cyrus SASL mysql plugin
323 Summary(pl):    Wtyczka mysql do Cyrus SASL
324 Group:          Libraries
325 Requires:       %{name} = %{version}
326
327 %description mysql
328 Cyrus SASL mysql plugin.
329
330 %description mysql -l pl
331 Wtyczka mysql do Cyrus SASL.
332
333 %prep
334 %setup  -q
335 %patch0 -p1
336 %patch1 -p1
337 %patch2 -p1
338 %patch3 -p1
339
340 cd doc
341 echo "cyrus-sasl complies with the following RFCs:" > rfc-compliance
342 ls rfc*.txt >> rfc-compliance
343 rm -f rfc*.txt
344 cd ..
345
346 %build
347 # acinclude.m4 contains only old libtool.m4
348 rm -f acinclude.m4 config/missing
349 %{__libtoolize}
350 %{__aclocal} -I cmulocal -I config
351 %{__autoheader}
352 %{__automake}
353 %{__autoconf}
354
355 cd saslauthd
356         %{__aclocal} -I ../cmulocal -I ../config -I config
357         %{__autoheader}
358         %{__automake}
359         %{__autoconf}
360 cd ..
361
362 LDFLAGS="%{rpmldflags} -ldl"; export LDFLAGS
363 %configure \
364         --enable-static \
365         --enable-login \
366         %{?_with_srp:--enable-srp} \
367         %{?!_without_mysql: --with-mysql=%{_prefix}} \
368         %{?!_without_ldap: --with-ldap=%{_prefix}} \
369         %{?_with_pwcheck: --with-pwcheck=/var/lib/sasl2} \
370         --with-saslauthd=/var/lib/sasl2 \
371         --with-pam \
372         --with-dblib=berkeley \
373         --with-dbpath=/var/lib/sasl2/sasl.db \
374         --with-configdir=%{_sysconfdir} \
375         --disable-krb4 \
376         --disable-gssapi
377 %{__make}
378
379 cd doc
380 RFCLIST=`grep 'rfc.\+\.txt' rfc-compliance`
381 for i in $RFCLIST; do
382         RFCDIR=../RFC/text/`echo $i | sed -e 's:^rfc::' -e 's:..\.txt$::' `00
383         echo -e ',s:'$i':'$RFCDIR/$i'\n,w\nq' | ed index.html
384 done
385 cd ..
386
387 %install
388 rm -rf $RPM_BUILD_ROOT
389 install -d $RPM_BUILD_ROOT{/var/lib/sasl2,%{_sysconfdir},/etc/{rc.d/init.d,sysconfig}} \
390                 $RPM_BUILD_ROOT%{_mandir}/man8
391
392 %{__make} install \
393         DESTDIR=$RPM_BUILD_ROOT
394
395 rm -rf $RPM_BUILD_ROOT%{_mandir}/cat*
396 rm -f $RPM_BUILD_ROOT%{_libdir}/sasl2/*.{la,a}
397
398 install {utils,saslauthd}/*.8 $RPM_BUILD_ROOT%{_mandir}/man8
399
400 ln -sf libsasl2.so $RPM_BUILD_ROOT%{_libdir}/libsasl.so
401
402 touch $RPM_BUILD_ROOT/var/lib/sasl2/sasl.db
403
404 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/saslauthd
405 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/saslauthd
406 install %{SOURCE3} ./cyrus.pam
407
408 %clean
409 rm -rf $RPM_BUILD_ROOT
410
411 %post
412 /sbin/ldconfig
413 echo "Remember to install appropriate plugins, or you won't have any mechs available."
414
415 %postun -p /sbin/ldconfig
416
417 %post saslauthd
418 /sbin/chkconfig --add saslauthd
419 if [ -f /var/lock/subsys/saslauthd ]; then
420         /etc/rc.d/init.d/saslauthd restart 1>&2
421 else
422         echo "Run \"/etc/rc.d/init.d/saslauthd start\" to start saslauthd."
423 fi
424
425 %preun saslauthd
426 if [ "$1" = "0" ]; then
427         if [ -f /var/lock/subsys/saslauthd ]; then
428                 /etc/rc.d/init.d/saslauthd stop 1>&2
429         fi
430         /sbin/chkconfig --del saslauthd
431 fi
432
433 %files
434 %defattr(644,root,root,755)
435 %doc AUTHORS COPYING ChangeLog NEWS README
436 %doc doc/{ONEWS,TODO,*.txt,*.html,*.fig,rfc-compliance}
437 %dir %{_sysconfdir}
438 %dir %{_libdir}/sasl2
439 %dir /var/lib/sasl2
440 %attr(755,root,root) %{_libdir}/lib*.so.*.*
441 %attr(755,root,root) %{_sbindir}/sasldblistusers2
442 %attr(755,root,root) %{_sbindir}/saslpasswd2
443
444 %attr(640,root,mail) %ghost %config(noreplace) %verify(not mtime md5 size) /var/lib/sasl2/sasl.db
445 %{_mandir}/man8/sasldblistusers2.*
446 %{_mandir}/man8/saslpasswd2.*
447
448 %files devel
449 %defattr(644,root,root,755)
450 %{_includedir}/sasl
451 %attr(755,root,root) %{_libdir}/lib*.so
452 %{_libdir}/lib*.la
453 %{_mandir}/man3/*
454
455 %files static
456 %defattr(644,root,root,755)
457 %{_libdir}/lib*.a
458
459 %files anonymous
460 %defattr(644,root,root,755)
461 %attr(755,root,root) %{_libdir}/sasl2/libanonymous.so*
462
463 %files cram-md5
464 %defattr(644,root,root,755)
465 %attr(755,root,root) %{_libdir}/sasl2/libcrammd5.so*
466
467 %files digest-md5
468 %defattr(644,root,root,755)
469 %attr(755,root,root) %{_libdir}/sasl2/libdigestmd5.so*
470
471 %files login
472 %defattr(644,root,root,755)
473 %attr(755,root,root) %{_libdir}/sasl2/liblogin.so*
474
475 %files otp
476 %defattr(644,root,root,755)
477 %attr(755,root,root) %{_libdir}/sasl2/libotp.so*
478
479 %files plain
480 %defattr(644,root,root,755)
481 %attr(755,root,root) %{_libdir}/sasl2/libplain.so*
482
483 %files sasldb
484 %defattr(644,root,root,755)
485 %attr(755,root,root) %{_libdir}/sasl2/libsasldb.so*
486
487 %if %{!?_without_mysql:1}%{?_without_mysql:0}
488 %files mysql
489 %defattr(644,root,root,755)
490 %attr(755,root,root) %{_libdir}/sasl2/libmysql*.so*
491 %endif
492
493 %if %{?_with_srp:1}%{?!_with_srp:0}
494 %files srp
495 %defattr(644,root,root,755)
496 %attr(755,root,root) %{_libdir}/sasl2/libsrp.so*
497 %endif
498
499 %if %{?_with_x509:1}%{?!_with_x509:0}
500 %files x509
501 %defattr(644,root,root,755)
502 %attr(755,root,root) %{_libdir}/sasl2/libx509.so*
503 %endif
504
505 %if %{?_with_pwcheck:1}%{?!_with_pwcheck:0}
506 %files pwcheck
507 %defattr(644,root,root,755)
508 %attr(755,root,root) %{_sbindir}/pwcheck
509 %endif
510
511 %files saslauthd
512 %defattr(644,root,root,755)
513 %doc cyrus.pam
514 %attr(755,root,root) %{_sbindir}/saslauthd
515 %attr(754,root,root) /etc/rc.d/init.d/saslauthd
516 %config(noreplace) %verify(not mtime md5 size) /etc/sysconfig/saslauthd
517 %{_mandir}/man8/saslauthd.*
This page took 0.094749 seconds and 3 git commands to generate.