# R&D # https://github.com/KoHead/mod_evasive # https://github.com/shivaas/mod_evasive # https://github.com/deasmi/mod_evasive # https://github.com/skonb/evasive # https://github.com/jbboehr/evasive %define debug_package %{nil} Summary: mod_dosevasive is an evasive maneuvers module for Apache. Name: tortix-mod_evasive Version: 1.10.1 Release: 16.1 Group: System Environment/Daemons Source0: mod_evasive_%{version}.tar.gz #Source1: mod_evasive.conf Patch1: relabel-blacklist.patch License: GPL URL: http://www.nuclearelephant.com/projects/dosevasive/ Provides: mod_dosevasive #BuildPrereq: /usr/sbin/apxs Requires: tortixd BuildRequires: tortixd-devel BuildRoot: %{_tmppath}/%{name}-%{version}-root %description mod_dosevasive is an evasive maneuvers module for Apache to provide evasive action in the event of an HTTP DoS or DDoS attack or brute force attack. It is also designed to be a detection and network management tool, and can be easily configured to talk to ipchains, firewalls, routers, and etcetera. mod_dosevasive presently reports abuses via email and syslog facilities. %prep %setup -q -n mod_evasive %patch1 -p1 # Several if/elif statements to use one RPM for both Apache versions %build %define _aslhome /var/asl %define _sysconfdir /var/asl/etc/ %define _prefix /var/asl/usr/ %define _bindir /var/asl/usr/bin/ %define _sbindir /var/asl/usr/sbin/ %define _includedir /var/asl/usr/include/ %define _mandir /var/asl/usr/share/man/ %define _libdir /var/asl/usr/lib/ %ifarch x86_64 %define _libdir /var/asl/usr/lib64/ %endif /var/asl/usr/sbin/apxs -Wc,"%{optflags}" -c mod_evasive20.c %install [ "%{buildroot}" != "/" ] && rm -rf %{buildroot} mkdir -pm 755 \ $RPM_BUILD_ROOT%{_libdir}/httpd/modules \ $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d install -pm 755 .libs/mod_evasive20.so $RPM_BUILD_ROOT%{_libdir}/httpd/modules/ #install -pm 644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/mod_evasive.conf %clean [ -n "%{buildroot}" -a "%{buildroot}" != / ] && rm -rf %{buildroot} [ -d %{_builddir}/%{name}-%{version} ] && rm -rf %{_builddir}/%{name}-%{version} %files %defattr(-,root,root,-) %doc README LICENSE CHANGELOG test.pl #%config(noreplace) %{_sysconfdir}/httpd/conf.d/* %{_libdir}/httpd/modules/* %changelog * Thu Jul 24 2014 Support 1.10.1-16 - Add conditional logic for Apache 2.4 support * Fri Dec 06 2013 Support 1.10.1-15 - Release bump to upgrade over epel packages * Thu Dec 05 2013 Support 1.10.1-5 - FR#1392, relabel "Blacklist" events as "Block" * Fri Dec 22 2006 Scott R. Shinn 1.10.1-3 - update to 1.10.1 - conf updates * Wed Aug 10 2005 Scott R. Shinn 1.10-2 - bugfix to conf.d * Sat Apr 02 2005 Scott R. Shinn 1.10 - update to 1.10 - dar modifications - remove %post functions * Tue Sep 02 2003 Larry Long - Upgrading to 1.8 for new whitelist feature * Sat Aug 30 2003 Larry Long - Added mod_dosevasive.conf/mod_dosevasive20.conf - Added module path for ldconfig - Added Include directive for httpd.conf - Added Apache restart at completion of installation * Fri Aug 29 2003 Larry Long - Initial RPM Build intended for standard Apache installations [1.3/2.0] - Modified src dir from 'dosevasive' to 'mod_dosevasive-1.7.1' for spec file