2013-06-12 14:43:29 +02:00
|
|
|
#
|
|
|
|
# spec file for package netsniff-ng
|
|
|
|
#
|
|
|
|
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
2012-03-29 13:40:21 +02:00
|
|
|
# Copyright (c) 2012 Pascal Bleser <pascal.bleser@opensuse.org>
|
|
|
|
#
|
|
|
|
# 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 http://bugs.opensuse.org/
|
2013-06-12 14:43:29 +02:00
|
|
|
#
|
2009-12-31 11:10:40 +01:00
|
|
|
|
2012-03-30 16:15:00 +02:00
|
|
|
|
2010-10-11 20:52:18 +02:00
|
|
|
Name: netsniff-ng
|
2013-06-12 14:43:29 +02:00
|
|
|
Version: 0.5.7
|
2010-10-11 20:52:18 +02:00
|
|
|
Release: 0
|
|
|
|
Summary: High Performance Network Sniffer for Packet Inspection
|
2013-06-12 14:43:29 +02:00
|
|
|
License: GPL-2.0+
|
|
|
|
Group: Productivity/Networking/Diagnostic
|
|
|
|
Url: http://netsniff-ng.org/
|
2012-03-29 13:40:21 +02:00
|
|
|
Source: http://www.netsniff-ng.org/pub/netsniff-ng/netsniff-ng-%{version}.tar.gz
|
2013-06-12 14:43:29 +02:00
|
|
|
# PATCH-FIX-SUSE netsniff-ng-cmake_pod2man_without_stderr.patch
|
2012-03-30 00:18:39 +02:00
|
|
|
Patch1: netsniff-ng-cmake_pod2man_without_stderr.patch
|
2013-06-12 14:43:29 +02:00
|
|
|
# PATCH-FIX-SUSE netsniff-ng-optflags.patch
|
2012-03-30 08:03:44 +02:00
|
|
|
Patch2: netsniff-ng-optflags.patch
|
2012-03-29 13:40:21 +02:00
|
|
|
BuildRequires: libGeoIP-devel
|
2013-06-12 14:43:29 +02:00
|
|
|
BuildRequires: ncurses-devel
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
2012-03-30 00:18:39 +02:00
|
|
|
%if 0%{?suse_version} >= 1130
|
|
|
|
BuildRequires: libnetfilter_conntrack-devel
|
|
|
|
BuildRequires: liburcu-devel
|
2013-06-12 14:43:29 +02:00
|
|
|
BuildRequires: nacl-devel
|
2012-03-30 00:18:39 +02:00
|
|
|
%define with_nf 1
|
|
|
|
%else
|
|
|
|
%define with_nf 0
|
|
|
|
%endif
|
2013-06-12 14:43:29 +02:00
|
|
|
BuildRequires: autoconf
|
|
|
|
BuildRequires: automake
|
2012-03-30 16:15:00 +02:00
|
|
|
BuildRequires: bison
|
2012-03-30 08:03:44 +02:00
|
|
|
BuildRequires: cmake >= 2.8
|
2013-06-12 14:43:29 +02:00
|
|
|
BuildRequires: flex
|
|
|
|
BuildRequires: gcc
|
|
|
|
BuildRequires: glibc-devel
|
|
|
|
BuildRequires: libcli-devel
|
|
|
|
BuildRequires: libnetfilter_conntrack-devel
|
|
|
|
BuildRequires: libnl-1_1-devel
|
|
|
|
BuildRequires: libtool
|
|
|
|
BuildRequires: make
|
|
|
|
BuildRequires: nacl-devel
|
2009-12-31 11:10:40 +01:00
|
|
|
|
|
|
|
%description
|
|
|
|
netsniff-ng is a high performance Linux network sniffer for packet inspection.
|
|
|
|
Basically, it is similar to tcpdump, but it doesn't need syscalls for fetching
|
|
|
|
packets. Instead, it uses an memory mapped area within kernel space for
|
|
|
|
accessing packets without the need of copying them to userspace ('zero-copy'
|
|
|
|
mechanism). It can be used for protocol analysis and reverse engineering,
|
|
|
|
network debugging, measurement of performance throughput, or network statistics
|
|
|
|
creation of incoming packets on central network nodes like routers or
|
|
|
|
firewalls.
|
|
|
|
|
|
|
|
%prep
|
2012-03-29 13:40:21 +02:00
|
|
|
%setup -q
|
2012-03-30 00:18:39 +02:00
|
|
|
%if 0%{?suse_version} < 1140
|
|
|
|
%patch1
|
|
|
|
%endif
|
2013-06-12 14:43:29 +02:00
|
|
|
%patch2 -p1
|
2009-12-31 11:10:40 +01:00
|
|
|
|
|
|
|
%build
|
2013-06-12 14:43:29 +02:00
|
|
|
install -d build
|
2012-03-29 13:40:21 +02:00
|
|
|
pushd build
|
|
|
|
cmake \
|
2013-06-12 14:43:29 +02:00
|
|
|
-DCMAKE_INSTALL_PREFIX="%{_prefix}" \
|
|
|
|
-DOPTFLAGS="%{optflags}" -DNACL_INCLUDE_DIR=%{_includedir}/nacl -DNACL_LIB_DIR=%{_libdir} \
|
2012-03-29 13:40:21 +02:00
|
|
|
../src/
|
2013-06-12 14:43:29 +02:00
|
|
|
make %{?_smp_mflags} VERBOSE=1
|
2012-03-29 13:40:21 +02:00
|
|
|
popd
|
2009-12-31 11:10:40 +01:00
|
|
|
|
|
|
|
%install
|
2012-03-29 13:40:21 +02:00
|
|
|
pushd build
|
2013-06-12 14:43:29 +02:00
|
|
|
make DESTDIR=%{buildroot} install
|
2012-03-29 13:40:21 +02:00
|
|
|
popd
|
2009-12-31 11:10:40 +01:00
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
2013-06-12 14:43:29 +02:00
|
|
|
%doc AUTHORS COPYING README REPORTING-BUGS
|
|
|
|
%doc Documentation
|
2009-12-31 11:10:40 +01:00
|
|
|
%config %{_sysconfdir}/netsniff-ng
|
2012-03-29 13:40:21 +02:00
|
|
|
%{_sbindir}/ashunt
|
2013-06-12 14:43:29 +02:00
|
|
|
%{_sbindir}/bpfc
|
|
|
|
%{_sbindir}/curvetun
|
2012-03-29 13:40:21 +02:00
|
|
|
%{_sbindir}/ifpps
|
2009-12-31 11:10:40 +01:00
|
|
|
%{_sbindir}/netsniff-ng
|
2012-03-29 13:40:21 +02:00
|
|
|
%{_sbindir}/trafgen
|
|
|
|
%doc %{_mandir}/man8/ashunt.8*
|
2013-06-12 14:43:29 +02:00
|
|
|
%doc %{_mandir}/man8/bpfc.8*
|
|
|
|
%doc %{_mandir}/man8/curvetun.8*
|
2012-03-29 13:40:21 +02:00
|
|
|
%doc %{_mandir}/man8/ifpps.8*
|
|
|
|
%doc %{_mandir}/man8/netsniff-ng.8*
|
|
|
|
%doc %{_mandir}/man8/trafgen.8*
|
2012-03-30 00:18:39 +02:00
|
|
|
%if %with_nf
|
|
|
|
%{_sbindir}/flowtop
|
|
|
|
%doc %{_mandir}/man8/flowtop.8*
|
|
|
|
%endif
|
2009-12-31 11:10:40 +01:00
|
|
|
|
2012-03-29 13:40:21 +02:00
|
|
|
%changelog
|