- fix config dir
[packages/apache-mod_evasive.git] / apache-mod_evasive.spec
CommitLineData
65012a01 1# TODO: cp spec name to apache-mod_evasive.spec as it is now official name
2# see http://www.nuclearelephant.com/projects/dosevasive/
6674f92f 3%define mod_name evasive
65012a01 4%define apxs /usr/sbin/apxs
5Summary: Apache DoS Evasive Maneuvers Module
6Summary(pl.UTF-8): Moduł manewrów omijających ataki DoS dla Apache
6674f92f 7Name: apache-mod_%{mod_name}
8Version: 1.10.1
65012a01 9Release: 5
10License: GPL v2+
6674f92f 11Group: Networking/Daemons/HTTP
65012a01 12Source0: http://www.zdziarski.com/projects/mod_evasive/mod_%{mod_name}_%{version}.tar.gz
6674f92f 13# Source0-md5: 784fca4a124f25ccff5b48c7a69a65e5
14Source1: %{name}.conf
15URL: http://www.zdziarski.com/projects/mod_evasive/
16BuildRequires: %{apxs}
65012a01 17BuildRequires: apache-devel >= 2.0
6674f92f 18BuildRequires: rpmbuild(macros) >= 1.268
65012a01 19BuildRequires: zlib-devel
6674f92f 20Requires: apache(modules-api) = %apache_modules_api
65012a01 21Provides: apache-mod_dosevasive
22Obsoletes: apache-mod_dosevasive
6674f92f 23BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
24
25%define _pkglibdir %(%{apxs} -q LIBEXECDIR 2>/dev/null)
40578bd1 26%define _sysconfdir %(%{apxs} -q SYSCONFDIR 2>/dev/null)/conf.d
6674f92f 27
28%description
65012a01 29mod_(dos)evasive is an evasive maneuvers module for Apache to provide
30evasive action in the event of an HTTP DoS or DDoS attack or brute
31force attack. It is also designed to be a detection and network
32management tool, and can be easily configured to talk to ipchains,
33firewalls, routers, and etcetera. mod_dosevasive presently reports
34abuses via email and syslog facilities.
6674f92f 35
36%description -l pl.UTF-8
65012a01 37mod_(dos)evasive to moduł manewrów omijających dla Apache, zapewniający
38akcje omijające w przypadku ataków DoS, DDoS lub brute force na usługę
39HTTP. Został zaprojektowany także jako narzędzie do wykrywania i
40zarządzania siecią, może być łatwo skonfigurowany do współpracy z
41ipchains, firewallami, routerami itp. mod_dosevasive obecnie raportuje
42nadużycia pocztą elektroniczną i poprzez sysloga.
6674f92f 43
44%prep
45%setup -q -n mod_%{mod_name}
46
47%build
65012a01 48%{apxs} -c mod_%{mod_name}20.c -lz
6674f92f 49
50%install
51rm -rf $RPM_BUILD_ROOT
40578bd1 52install -d $RPM_BUILD_ROOT{%{_pkglibdir},%{_sysconfdir}}
65012a01 53
40578bd1
ER
54install -p .libs/mod_%{mod_name}20.so $RPM_BUILD_ROOT%{_pkglibdir}/mod_%{mod_name}.so
55cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/80_mod_%{mod_name}.conf
6674f92f 56
57%clean
58rm -rf $RPM_BUILD_ROOT
59
60%post
61%service -q httpd restart
62
63%postun
64if [ "$1" = "0" ]; then
65 %service -q httpd restart
66fi
67
68%files
69%defattr(644,root,root,755)
70%doc README
40578bd1 71%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*_mod_%{mod_name}.conf
e9af2617 72%attr(755,root,root) %{_pkglibdir}/*.so
This page took 0.0422940000000001 seconds and 4 git commands to generate.