File tcpdump.spec of Package tcpdump

#
# spec file for package tcpdump (Version 4.0.0)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# 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/
#

# norootforbuild


Name:           tcpdump
BuildRequires:  libpcap-devel libsmi-devel openssl-devel
Version:        4.0.0
Release:        1
AutoReqProv:    on
License:        BSD 3-Clause
Group:          Productivity/Networking/Diagnostic
Url:            http://www.tcpdump.org/
Summary:        A Packet Sniffer
Source:         %{name}-%{version}.tar.bz2
Source1:        %{name}-qeth
Patch0:         %{name}-%{version}-prototypes.patch
Patch1:         %{name}-%{version}-autoconf.patch
Patch2:         %{name}-%{version}-aliasing.patch
Patch3:         %{name}-%{version}-uninitialized.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
This program can "read" all or only certain packets going over the
ethernet. It can be used to debug specific network problems.



%prep
%setup -q
%patch0
%patch1
%patch2
%patch3

%build
export CFLAGS="$RPM_OPT_FLAGS -Wall -DGUESS_TSO -fstack-protector"
%configure \
  --enable-ipv6
make

%install
make DESTDIR=$RPM_BUILD_ROOT install
%ifarch s390 s390x
  install -D -m 755 $RPM_SOURCE_DIR/tcpdump-qeth $RPM_BUILD_ROOT%{_sbindir}
%endif

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root)
%doc CHANGES CREDITS LICENSE README *.awk
%doc %{_mandir}/man?/*
%{_sbindir}/*

%changelog
* Wed Jan 14 2009 prusnak@suse.cz
- updated to 4.0.0
  * Add support for Bluetooth Sniffing
  * Add support for Realtek Remote Control Protocol (openrrcp.org.ru)
  * Add support for 802.11 AVS
  * Add support for SMB over TCP
  * Add support for 4 byte BGP AS printing
  * Add support for compiling on case-insensitive file systems
  * Add support for ikev2 printing
  * Update support for decoding AFS
  * Update DHCPv6 printer
  * Use newer libpcap API's (allows -B option on all platforms)
  * Add -I to turn on monitor mode
  * Bugfixes in lldp, lspping, dccp, ESP, NFS printers
  * Cleanup unused files and various cruft
- dropped obsoleted juniper.patch (included in update)
* Tue Jan 08 2008 prusnak@suse.cz
- updated to 3.9.8
  * Rework ARP printer
  * Rework OSPFv3 printer
  * Add support for Frame-Relay ARP
  * Decode DHCP Option 121 (RFC 3442 Classless Static Route)
  * Decode DHCP Option 249 (MS Classless Static Route) the same as Option 121
  * TLV: Add support for Juniper .pcap extensions
  * Print EGP header in new-world-order style
  * Converted print-isakmp.c to NETDISSECT
  * Moved AF specific stuff into af.h
  * Test subsystem now table driven, and saves outputs and diffs to one place
  * Require <net/pfvar.h> for pf definitions - allows reading of pflog formatted
  libpcap files on an OS other than where the file was generated
* Thu Jul 26 2007 prusnak@suse.cz
- updated to 3.9.7
  * NFS: Print unsigned values as such
  * RX: parse safely
  * BGP: fixes for IPv6-less builds
  * 801.1ag: use standard codepoint
  * use /dev/bpf on systems with such a device
  * 802.11: print QoS data, avoid dissect of no-data frame, ignore padding
  * smb: make sure that we haven't gone past the end of the captured data
  * smb: squelch an uninitialized complaint from coverity
  * NFS: from NetBSD; don't interpret the reply as a possible NFS reply if it got MSG_DENIED
  * BGP: don't print TLV values that didn't fit, from www.digit-labs.org
  * revised INSTALL.txt about libpcap dependancy
- dropped obsolete patch:
  * bgp-overflow.diff (fixed in update)
  * 802_11-overflow.diff (included in update)
- changed libpcap to libpcap-devel in BuildRequires
* Thu Jul 12 2007 prusnak@suse.cz
- update to 3.9.6
  * added support for:
    - OIF RSVP Extensions UNI 1.0 Rev. 2 and additional RSVP objects
    - Message-id NACK c-type
    - 802.3ah loopback ctrl msg
    - Multiple-STP as per 802.1s
    - rapid-SPT as per 802.1w
    - CFM Link-trace msg, Link-trace-Reply msg,
    - unidirectional link detection
    - the olsr protocol as per RFC 3626 plus the LQ extensions from olsr.org
    - variable-length checksum in DCCP, as per section 9 of RFC 4340
    - per-VLAN spanning tree and per-VLAN rapid spanning tree
    - Multiple-STP as per 802.1s
    - the cisco propriatry 'dynamic trunking protocol'
    - the cisco proprietary VTP protocol
    - additional values in pflog
  * changes to both TCP and IP Printer Output
  * fixed a potential buffer overflow in the 802.11 printer
  * print basic info about a few more Cisco LAN protocols
  * mDNS cleanup
  * ICMP MPLS rework of the extension code
  * use the correct codepoint for the OSPF simple text auth token entry
  * use safeputs to print the password
  * update dhcp6 options table as per IETF standardization activities
- fixed overflow in bgp (bgp-overflow.patch) [#291356]
* Fri Mar 02 2007 prusnak@suse.cz
- fixed one byte overflow (802_11-overflow.diff) [#250163]
* Wed Jan 03 2007 prusnak@suse.cz
- update to 3.9.5
  * Fixes for 64bit compiling
  * Updated list of DNS RR typecodes
  * Add basic support for keyed authentication TCP option
  * Fix printing for 4.4BSD/NetBSD NFS Filehandles
  * Add support for:
    - Frame-Relay ARP
    - parsing Juniper .pcap files
    - FRF.16 Multilink Frame-Relay (DLT_MFR)
    - PIMv2 checksum verification
    - further dissection of the IPCP Compression Option
    - Cisco's proposed VQP protocol
    - Cisco style NLPID encapsulation
    - PPP over Frame-Relay
    - Address-Withdraw and Label-Withdraw Msgs
    - BFD Discriminator TLV
    - BGP signaled VPLS
* Wed Jan 25 2006 mls@suse.de
- converted neededforbuild to BuildRequires
* Thu Jan 12 2006 mjancar@suse.cz
- compile with -fstack-protector
* Mon Jan 09 2006 mjancar@suse.cz
- update to 3.9.4
- drop obsolete patches
  * tcpdump-3.9.4-overflow.diff
* Thu Sep 01 2005 mjancar@suse.cz
- enable support for TSO packets (#114159)
* Fri Aug 05 2005 cthiel@suse.de
- fixed buffer overflow in addrtoname.c:499
* Tue Aug 02 2005 mjancar@suse.cz
- update to 3.9.3
* Thu Aug 05 2004 postadal@suse.cz
- updated to version 3.8.3
- removed obsoleted patches (isakmp-fix2, isakmp-fix3, radius-fix)
* Mon Mar 29 2004 postadal@suse.cz
- fixed overflow in ISAKMP (CAN-2004-0183) [#36828]
* Fri Feb 06 2004 ro@suse.de
- fix configure.in (test for pcap_debug was broken)
* Tue Jan 20 2004 postadal@suse.cz
- updated to version 3.8.1
  * fixed security bug in L2TP (CAN-2003-1029)
- removed obsoleted patches (isakmp-buffer-overflow-fix, compile)
- fixed security bugs in these parsers: RADIUS (CAN-2004-0055),
  ISAKMP (CAN-2004-0057) [#33763]
* Sat Jan 10 2004 adrian@suse.de
- build as user
* Tue Jan 06 2004 postadal@suse.cz
- fixed two remotely exploitable buffer overflows in the ISAKMP parser
  [#33763] (CAN-2003-0989)
* Thu Jul 24 2003 postadal@suse.cz
- updated to version 3.7.2
- removed obsoleted patches (tcpdump-nfs-fix, tcpdump-isakmp, tcpdump-bgp)
* Wed May 07 2003 ro@suse.de
- make it compile with current glibc headers
  (move include of netinet/in.h further up)
* Wed Mar 05 2003 postadal@suse.cz
- fixed security bugs in parsing ISAKMP, BGP and NFS
* Tue Oct 01 2002 froh@suse.de
- s390/s390x: dumping of qeth interfaces needs some filtering, which
  is accomplished by the new 'tcpdump-qeth' (#15626, #22085)
* Mon May 20 2002 postadal@suse.de
- fixed bug in displaying NFS traffic
- updated to version 3.7.1
  * support more protocols
  * better Linux libc5 compat
* Wed Apr 03 2002 postadal@suse.cz
- fixed to compile with autoconf-2.53
* Mon Jun 18 2001 cihlar@suse.cz
- updated to version 3.6.2
- removed obsolete patches
- compile against package libpcap
* Tue Feb 06 2001 ro@suse.de
- tcpclice.c: include time.h
- smbutil.c: include time.h
* Fri Jan 19 2001 bk@suse.de
- Turn off PACKET_RX_RING too. It is not available in lx_sus22 and
  not enabled in our 2.4 kernel configs and causes a warning on
  every start and possible trouble. See bug #5178
* Thu Jan 11 2001 ak@suse.de
- Turn off PACKET_TRECV. It's not enabled in our kernel and causes some
  problems.
* Fri Nov 24 2000 ak@suse.de
- Add mb() for ppc
* Tue Nov 14 2000 ro@suse.de
- groups sorted
* Tue Nov 14 2000 ak@suse.de
- add some protocols to make it build on 6.1 again
* Mon Nov 13 2000 ak@suse.de
- add membar fix for sparc
* Sat Nov 11 2000 ak@suse.de
- fix some buffer overflows.
* Thu May 18 2000 schwab@suse.de
- Fix missing declaration.
- Fix broken includes.
- Get rid of Makefile.Linux and clean up spec file.
- Update config.{sub,guess}.
* Thu May 11 2000 ak@suse.de
- add security fix for endless dns looping. From Guy Harris.
* Thu Mar 02 2000 ak@suse.de
- move man pages to /usr/share/man
* Wed Dec 22 1999 ak@suse.de
- fix promiscuous mode bug
* Fri Dec 03 1999 bk@suse.de
- disabled NO_SMP_DEBUG changes by ank(did not compile on sparc)
* Sat Nov 06 1999 bk@suse.de
- Integrated changes from ak:
  strip tcpdump and a fix a -p crash bug (pcap-maddr-fix)
* Wed Oct 27 1999 bk@suse.de
- Andi Kleen added patches from Alexey Kuznetsov. Features e.g.:
  - device independent libpcap, Kernel support for new link-layers, e.g. ISDN
  (libpcap uses PF_PACKET,SOCK_DGRAM instead of PF_INET,SOCK_PACKET)
  - IPv6 and APM support, SMB updates
  - libpcap support for "In Kernel Packet Filtering" (CONFIG_FILTER)
- made a libpcapn subpackage which holds the new libpcap for developers.
- Added fix to reestablish old output format of tcpdump from Andi Kleen.
* Mon Sep 13 1999 bs@suse.de
- ran old prepare_spec on spec file to switch to new prepare_spec.
* Tue Sep 29 1998 ro@suse.de
- print_i4l : include net/ethernet.h instead of netinet/if_ether.h for glibc
* Mon Mar 02 1998 florian@suse.de
- update to version 3.4a6
* Mon Jul 07 1997 florian@suse.de
- update to version 3.4a5
- added isdn-patches
- update to version 3.4a3
* Sun Apr 13 1997 florian@suse.de
- update to new version 3.3.1a2 with automatic detection of packet types
* Thu Jan 02 1997 florian@suse.de
- added the changes distributed with samba
- added isdn patches
openSUSE Build Service is sponsored by