File fwlogwatch.spec of Package fwlogwatch

# vim: set sw=4 ts=4 et nu:
# spec file for package fwlogwatch
# Copyright (C) 2000-2013 Boris Wesslowski
# Copyright (c) 2013 Bruno Friedmann <>
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
# $Id: fwlogwatch.spec 723 2011-11-11 15:31:16Z bw $
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via
# @TODOS : 
#	create patch for Licence
#	create patch for removing and adapting all /usr/local references

Name: 		fwlogwatch
Summary: 	Firewall log analyzer, report generator and realtime response agent
Version: 	1.5
Release: 	0
Group: 		Productivity/Networking/Security
License: 	GPL-2.0
Source: 	%{name}-%{version}.tar.bz2
Patch:		gpl-license.patch
BuildRoot: 	%_tmppath/%{name}-%{version}-buildroot
BuildRequires: 	flex
BuildRequires:  gcc
BuildRequires:  make
BuildRequires:  pkgconfig
BuildRequires:  libtool
BuildRequires:  zlib-devel
BuildRequires:	gettext-devel
%if %suse_version < 1220
BuildRequires:  iptables-devel
BuildRequires:  libiptc-devel
BuildRequires:  libxtables-devel
Requires:	gettext
PreReq:         %fillup_prereq
PreReq:         %insserv_prereq
Recommends:	apache2
%define        cgidir /srv/www/cgi-bin

fwlogwatch produces Linux ipchains, Linux netfilter/iptables,
Solaris/BSD/IRIX/HP-UX ipfilter, Cisco IOS, Cisco PIX/ASA, NetScreen, Elsa
Lancom router and Snort IDS log summary reports in plain text and HTML form
and has a lot of options to analyze and display relevant patterns. It also
can run as daemon (with web interface) doing realtime log monitoring and
reporting anomalies or starting attack countermeasures.

%setup -q -n %{name}-%{version}

%__make %{?_smp_mflags} CC="%__cc" OPTFLAGS="%{optflags}"

%__install -d "%{buildroot}%{_sbindir}"
%__install -d "%{buildroot}%{_sysconfdir}/init.d"
%__install -d "%{buildroot}%{_mandir}/man8"
%__install -d "%{buildroot}%{_datadir}/locale/de/LC_MESSAGES"
%__install -d "%{buildroot}%{_datadir}/locale/ja/LC_MESSAGES"
%__install -d "%{buildroot}%{_datadir}/locale/pt/LC_MESSAGES"
%__install -d "%{buildroot}%{_datadir}/locale/sv/LC_MESSAGES"
%__install -d "%{buildroot}%{_datadir}/locale/zh_CN/LC_MESSAGES"
%__install -d "%{buildroot}%{_datadir}/locale/zh_TW/LC_MESSAGES"
%__make install INSTALL_DIR="%{buildroot}%{_prefix}"
%__make install-config CONF_DIR="%{buildroot}%{_sysconfdir}"
%__make install-i18n LOCALE_DIR="%{buildroot}%{_prefix}"
%if %suse_version < 1210
%__install -m contrib/fwlogwatch.init.suse "%{buildroot}%{_sysconfdir}/init.d/fwlogwatch"



%doc contrib/fwlogsummary.cgi contrib/fwlogsummary_small.cgi
%doc contrib/fwlogwatch.php
%config(noreplace) %{_sysconfdir}/fwlogwatch.config
%if %suse_version < 1210
%config(noreplace) %{_sysconfdir}/init.d/fwlogwatch
%lang(de) %{_datadir}/locale/de/LC_MESSAGES/
%lang(ja) %{_datadir}/locale/ja/LC_MESSAGES/
%lang(pt) %{_datadir}/locale/pt/LC_MESSAGES/
%lang(sv) %{_datadir}/locale/sv/LC_MESSAGES/
%lang(zh_CN) %{_datadir}/locale/zh_CN/LC_MESSAGES/
%lang(zh_TW) %{_datadir}/locale/zh_TW/LC_MESSAGES/