3 # - alternative module: http://www.muquit.com/muquit/software/mod_auth_ldap/mod_auth_ldap.html
4 # - http://www.muquit.com/muquit/software/mod_auth_ldap/mod_auth_ldap.tar.gz
5 # - 1.6.1 fails to connect to ldap:
6 # Could not connect to LDAP server: No such file or directory
7 # Could not connect to LDAP server: Success
10 %bcond_with ssl # build with ssl (requires netscape sdk), tls is available with openldap
12 %define mod_name auth_ldap
13 %define apxs /usr/sbin/apxs1
14 Summary: This is a LDAP authentication module for Apache
15 Summary(cs.UTF-8): Autentizační modul LDAP pro WWW server Apache
16 Summary(da.UTF-8): En LDAP-autenticeringsmodul for Apache
17 Summary(de.UTF-8): Ein LDAP Authentifizierungsmodul für Apache
18 Summary(es.UTF-8): Este módulo proporciona autenticación LDAP para Apache
19 Summary(fr.UTF-8): Module d'authentification LDAP pour Apache
20 Summary(id.UTF-8): Module LDAP authentication untuk Apache
21 Summary(it.UTF-8): Modulo di autenticazione LDPA per Apache
22 Summary(ja.UTF-8): Apache 用の LDAP 認証モジュール
23 Summary(nb.UTF-8): En LDAP-autentiseringsmodul for Apache
24 Summary(pl.UTF-8): Moduł uwierzytelnienia LDAP dla Apache
25 Summary(pt.UTF-8): Um módulo de autenticação de LDAP para o Apache
26 Summary(pt_BR.UTF-8): Este módulo provê autenticação LDAP para o Apache
27 Summary(ru.UTF-8): Аутентификационный модуль LDAP для сервера Apache
28 Summary(sl.UTF-8): Avtentikacijski modul LDAP za Apache
29 Summary(sv.UTF-8): En LDAP autentiseringsmodul för Apache
30 Summary(zh_CN.UTF-8): 这是用于 Apache 的 LDAP 验证模块
31 Name: apache1-mod_%{mod_name}
32 # 1.6.1 is broken, ensure it works for you before building this
33 # meanwhile stable version is on "v1.6.0" branch
37 Group: Networking/Daemons
38 Source0: http://www.rudedog.org/auth_ldap/auth_ldap-%{version}.tar.gz
39 # Source0-md5: a78d8c5fc77086562ca056c226c97992
40 Patch0: %{name}-makefile.patch
41 URL: http://www.rudedog.org/auth_ldap/
42 BuildRequires: apache1-devel >= 1.3.39
43 BuildRequires: autoconf
45 BuildRequires: openldap-devel >= 2.3.0
46 %{?with_ssl:BuildRequires: mozldap-devel}
47 BuildRequires: rpmbuild(macros) >= 1.268
48 Requires: apache1(EAPI)
49 Requires: apache1-mod_auth
50 Obsoletes: apache-mod_auth_ldap < 1.6.0
51 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
53 %define _pkglibdir %(%{apxs} -q LIBEXECDIR 2>/dev/null)
54 %define _sysconfdir %(%{apxs} -q SYSCONFDIR 2>/dev/null)
57 This is an authentication module for Apache that allows you to
58 authenticate HTTP clients using user entries in an LDAP directory.
60 %description -l cs.UTF-8
61 Balíček obsahuje autentizační modul pro WWW server Apache, který
62 umožňuje autentizovat HTTP klienty proti položkám v adresářové službě
65 %description -l da.UTF-8
66 Denne pakke indeholder en autenticeringsmodul for webtjeneren Apache -
67 med auth_ldap installeret kan HTTP-klienter autenticeres mod
68 brugerinformation i et LDAP-katalog.
70 %description -l de.UTF-8
71 Dieses Paket enthält ein Authentifizierungs-Modul für den Apache
72 Webserver, das Ihnen ermöglicht, HTTP-Clients mit Hilfe von
73 Benutzereinträgen in einem LDAP-Verzeichniss zu authentifizieren.
75 %description -l es.UTF-8
76 Este paquete contiene un módulo de autenticación para el servidor
77 Apache web que le permite autenticar clientes HTTP usando entradas de
78 usuario en un directorio LDAP.
80 %description -l fr.UTF-8
81 Ce paquetage contient un module d'authentification pour le serveur Web
82 Apache, qui vous permet d'authentifier les clients HTTP en utilisant
83 les entrées utilisateur dans un répertoire LDAP.
85 %description -l id.UTF-8
86 Ini adalah authentication module untuk Apache yang memungkinkan anda
87 melakukan otentikasi HTTP client menggunakan user entry di dalam LADP
90 %description -l it.UTF-8
91 Questo pacchetto contiene un modulo di autenticazione per il Web
92 server Apache che consente di autenticare i client HTTP tramite gli
93 inserimenti utente in una directory LDPA.
95 %description -l ja.UTF-8
96 このパッケージには Apache Web サーバーで LDAP ディレクトリ内のユーザー
97 エントリを使った HTTP クライアントの認証を可能にするための認証
100 %description -l nb.UTF-8
101 Denne pakken inneholder en autentiseringsmodul for webtjeneren Apache
102 - med auth_ldap installert kan HTTP-klienter autentiseres mot
103 brukerinformasjon i en LDAP-katalog.
105 %description -l pl.UTF-8
106 W pakiecie znajduje się moduł do Apache, który pozwala na
107 uwierzytelnianie klientów HTTP przy użyciu LDAP.
109 %description -l pt.UTF-8
110 Este pacote contém um módulo de autenticação para o servidor Web
111 Apache que lhe permite autenticar os clientes HTTP usando registos de
112 utilizadores numa directoria LDAP.
114 %description -l pt_BR.UTF-8
115 Este módulo permite que você autentique clientes HTTP usando o
118 %description -l ru.UTF-8
119 Это модуль аутентификации для Apache, позволяющий идентифицировать
120 HTTP-клиентов на основе записей пользователя в каталоге LDAP.
122 %description -l sv.UTF-8
123 Detta paket innehåller en autenticeringsmodul för webbservern Apache
124 som låter dig autenticera HTTP-klienter med använderposter i en
127 %description -l zh_CN.UTF-8
128 这是用于 Apache 的验证模块,它允许您使用 LDAP 目录中的用户项验证 HTTP
132 %setup -q -n auth_ldap-%{version}
134 mv -f auth_ldap.c mod_auth_ldap.c
136 lynx -nolist -dump auth_ldap.html > auth_ldap.txt
141 --with-apxs=%{apxs} \
142 --with-ldap-sdk=openldap \
143 --with-shared-cache \
144 --with%{!?with_ssl:out}-ssl
149 rm -rf $RPM_BUILD_ROOT
150 install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}/conf.d}
152 install mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir}
154 echo 'LoadModule %{mod_name}_module modules/mod_%{mod_name}.so' > \
155 $RPM_BUILD_ROOT%{_sysconfdir}/conf.d/90_mod_%{mod_name}.conf
158 rm -rf $RPM_BUILD_ROOT
161 %service -q apache restart
164 if [ "$1" = "0" ]; then
165 %service -q apache restart
168 %triggerpostun -- apache1-mod_%{mod_name} < 1.6.0-1.1
169 # check that they're not using old apache.conf
170 if grep -q '^Include conf\.d' /etc/apache/apache.conf; then
171 sed -i -e '/^\(Add\|Load\)Module.*mod_%{mod_name}\.\(so\|c\)/d' /etc/apache/apache.conf
175 %defattr(644,root,root,755)
176 %doc *.html PROBLEMS auth_ldap.txt
177 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/conf.d/*_mod_%{mod_name}.conf
178 %attr(755,root,root) %{_pkglibdir}/mod_auth_ldap.so