%define mod_name auth_mellon %define apxs %{_sbindir}/apxs Summary: A SAML 2.0 authentication module for the Apache Httpd Server Name: apache-mod_%{mod_name} Version: 0.7.0 Release: 1 License: GPL v2+ Group: Networking/Daemons/HTTP Source0: https://modmellon.googlecode.com/files/mod_auth_mellon-%{version}.tar.gz # Source0-md5: b1d58363c6feb00a39402b347bc2e17b Source1: auth_mellon.conf Source3: mod_auth_mellon.tmpfiles Source4: mellon_create_metadata.sh URL: https://code.google.com/p/modmellon/ BuildRequires: %{apxs} BuildRequires: apache-devel >= 2.2 BuildRequires: curl-devel BuildRequires: glib2-devel BuildRequires: lasso-devel BuildRequires: openssl-devel BuildRequires: rpmbuild(macros) >= 1.268 BuildRequires: xmlsec1-devel Requires: apache(modules-api) = %apache_modules_api Requires: lasso >= 2.3.6 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) %define _pkglibdir %(%{apxs} -q LIBEXECDIR 2>/dev/null) %define _sysconfdir %(%{apxs} -q SYSCONFDIR 2>/dev/null)/conf.d %description The mod_auth_mellon module is an authentication service that implements the SAML 2.0 federation protocol. It grants access based on the attributes received in assertions generated by a IdP server. %prep %setup -q -n mod_%{mod_name}-%{version} %build %configure \ APXS=%{apxs} %{__make} %install rm -rf $RPM_BUILD_ROOT install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir},%{systemdtmpfilesdir},%{_libdir}/%{name},/var/run/mod_%{mod_name}} install -p .libs/mod_%{mod_name}.so $RPM_BUILD_ROOT%{_pkglibdir} cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/90_mod_%{mod_name}.conf cp -p %{SOURCE3} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/%{name}.conf cp -p %{SOURCE4} $RPM_BUILD_ROOT%{_libdir} %clean rm -rf $RPM_BUILD_ROOT %files %defattr(644,root,root,755) %doc README COPYING %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*_mod_%{mod_name}.conf %attr(755,root,root) %{_pkglibdir}/mod_%{mod_name}.so %attr(755,root,root) %{_libdir}/mellon_create_metadata.sh %dir %attr(755,http,http) /var/run/mod_%{mod_name} %{systemdtmpfilesdir}/%{name}.conf