From ac9e55d9679b2add31d50b8db7fbbd1fa39a5876687b317a4088d2ff607faff6 Mon Sep 17 00:00:00 2001 From: Andreas Stieger Date: Fri, 15 Aug 2014 19:55:11 +0000 Subject: [PATCH] Accepting request 244895 from home:AndreasStieger:branches:network:utilities tcpdump 4.6.1 OBS-URL: https://build.opensuse.org/request/show/244895 OBS-URL: https://build.opensuse.org/package/show/network:utilities/tcpdump?expand=0&rev=19 --- tcpdump-4.0.0-aliasing.patch | 118 --------------------------------- tcpdump-4.0.0-prototypes.patch | 23 ------- tcpdump-4.5.1.tar.gz | 3 - tcpdump-4.5.1.tar.gz.sig | Bin 419 -> 0 bytes tcpdump-4.6.1.tar.gz | 3 + tcpdump-4.6.1.tar.gz.sig | Bin 0 -> 419 bytes tcpdump.changes | 29 ++++++++ tcpdump.spec | 36 +++++----- 8 files changed, 48 insertions(+), 164 deletions(-) delete mode 100644 tcpdump-4.0.0-aliasing.patch delete mode 100644 tcpdump-4.0.0-prototypes.patch delete mode 100644 tcpdump-4.5.1.tar.gz delete mode 100644 tcpdump-4.5.1.tar.gz.sig create mode 100644 tcpdump-4.6.1.tar.gz create mode 100644 tcpdump-4.6.1.tar.gz.sig diff --git a/tcpdump-4.0.0-aliasing.patch b/tcpdump-4.0.0-aliasing.patch deleted file mode 100644 index 2bc52fe..0000000 --- a/tcpdump-4.0.0-aliasing.patch +++ /dev/null @@ -1,118 +0,0 @@ -Index: icmp6.h -=================================================================== ---- icmp6.h.orig -+++ icmp6.h -@@ -404,7 +404,11 @@ struct icmp6_router_renum { /* router re - u_int8_t rr_segnum; - u_int8_t rr_flags; - u_int16_t rr_maxdelay; -+ union { -+ u_int8_t rr_reserved8[4]; -+ u_int16_t rr_reserved16[2]; - u_int32_t rr_reserved; -+ }; - }; - #define ICMP6_RR_FLAGS_TEST 0x80 - #define ICMP6_RR_FLAGS_REQRESULT 0x40 -Index: print-icmp.c -=================================================================== ---- print-icmp.c.orig -+++ print-icmp.c -@@ -47,6 +47,12 @@ static const char rcsid[] _U_ = - * Per RFC 792, September 1981. - */ - -+/* rfc1191 */ -+struct mtu_discovery { -+ u_int16_t unused; -+ u_int16_t nexthopmtu; -+}; -+ - /* - * Structure of an icmp header. - */ -@@ -61,8 +67,12 @@ struct icmp { - u_int16_t icd_id; - u_int16_t icd_seq; - } ih_idseq; -+ union { - u_int32_t ih_void; -+ struct mtu_discovery ih_mtu_discovery; -+ }; - } icmp_hun; -+#define icmp_mtu_discovery icmp_hun.ih_mtu_discovery - #define icmp_pptr icmp_hun.ih_pptr - #define icmp_gwaddr icmp_hun.ih_gwaddr - #define icmp_id icmp_hun.ih_idseq.icd_id -@@ -243,12 +253,6 @@ static struct tok type2str[] = { - { 0, NULL } - }; - --/* rfc1191 */ --struct mtu_discovery { -- u_int16_t unused; -- u_int16_t nexthopmtu; --}; -- - /* rfc1256 */ - struct ih_rdiscovery { - u_int8_t ird_addrnum; -@@ -413,7 +417,7 @@ icmp_print(const u_char *bp, u_int plen, - case ICMP_UNREACH_NEEDFRAG: - { - register const struct mtu_discovery *mp; -- mp = (struct mtu_discovery *)(u_char *)&dp->icmp_void; -+ mp = &dp->icmp_mtu_discovery; - mtu = EXTRACT_16BITS(&mp->nexthopmtu); - if (mtu) { - (void)snprintf(buf, sizeof(buf), -Index: print-icmp6.c -=================================================================== ---- print-icmp6.c.orig -+++ print-icmp6.c -@@ -1279,7 +1279,7 @@ icmp6_rrenum_print(const u_char *bp, con - printf("seg=%u,", rr6->rr_segnum); - printf("maxdelay=%u", EXTRACT_16BITS(&rr6->rr_maxdelay)); - if (rr6->rr_reserved) -- printf("rsvd=0x%x", EXTRACT_32BITS(&rr6->rr_reserved)); -+ printf("rsvd=0x%x", EXTRACT_16BITS(&rr6->rr_reserved16[0])); - /*[*/ - printf("]"); - #undef F -Index: print-timed.c -=================================================================== ---- print-timed.c.orig -+++ print-timed.c -@@ -86,8 +86,8 @@ timed_print(register const u_char *bp) - fputs(" [|timed]", stdout); - return; - } -- sec = EXTRACT_32BITS(&tsp->tsp_time.tv_sec); -- usec = EXTRACT_32BITS(&tsp->tsp_time.tv_usec); -+ sec = EXTRACT_32BITS(&tsp->tsp_time.tv_sec32[0]); -+ usec = EXTRACT_32BITS(&tsp->tsp_time.tv_usec32[0]); - if (usec < 0) - /* corrupt, skip the rest of the packet */ - return; -Index: timed.h -=================================================================== ---- timed.h.orig -+++ timed.h -@@ -54,7 +54,16 @@ struct tsp { - u_int8_t tsp_vers; - u_int16_t tsp_seq; - union { -- struct tsp_timeval tspu_time; -+ struct { -+ union { -+ int tv_sec32[2]; -+ long tv_sec; -+ }; -+ union { -+ int tv_usec32[2]; -+ long tv_usec; -+ }; -+ } tspu_time; - int8_t tspu_hopcnt; - } tsp_u; - int8_t tsp_name[256]; diff --git a/tcpdump-4.0.0-prototypes.patch b/tcpdump-4.0.0-prototypes.patch deleted file mode 100644 index 99e927b..0000000 --- a/tcpdump-4.0.0-prototypes.patch +++ /dev/null @@ -1,23 +0,0 @@ ---- print-radius.c -+++ print-radius.c -@@ -56,6 +56,7 @@ - #include - - #include -+#include - - #include "interface.h" - #include "addrtoname.h" ---- setsignal.c -+++ setsignal.c -@@ -39,6 +39,10 @@ - #include "os-proto.h" - #endif - -+#ifdef HAVE_SIGSET -+void *sigset(int signum, void (*handler)(int)); -+#endif -+ - #include "setsignal.h" - - /* diff --git a/tcpdump-4.5.1.tar.gz b/tcpdump-4.5.1.tar.gz deleted file mode 100644 index 1a6fda8..0000000 --- a/tcpdump-4.5.1.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:14ab39657128f3a650aed4cf455f76c7590601087b6101c253d698f6e73f0b96 -size 1024455 diff --git a/tcpdump-4.5.1.tar.gz.sig b/tcpdump-4.5.1.tar.gz.sig deleted file mode 100644 index 97cf1ec5505b3ba8070a8e6e98ff48c68d68ad1bd5bbef1de885587ed4913355..0000000000000000000000000000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 419 zcmV;U0bKrx0iXl`0RjL91p-ox&C&o02@v3k-tpPNT@8tV3?QSNsbPDZ38f4I=IQRCsP3oSgb56U44YmfN^1>{g zj!AdLlcygFG!4ff9z|CwlviI1qvu_~wu~N^*A!27hXMZvCW_>-nJt&uk{iW@dRWzd z0*sX1`RvBwnnYaX&hVe-Lf0x++sS}Tf`dv0QKqZNig91Qk)vnM(Auv|eUZgU=~gy_ z*2#;pK&#v!rFz_XD%pP3Zue2-Q`@@ zNI0o&dglX9%f#_06|IpQdU7__F*4Nzpf;z5Gg zAHx5R5(NyZF|XgK@R1U`@rzsVsP z(&nQBFpZH(lKVAF{8V(Py4GjrfDkejX=eg+7xdDUu7?=Vj`YlUeDsT^#9RSQA}Pna N6JCe)vZ@EwHjyGn&lmsz literal 0 HcmV?d00001 diff --git a/tcpdump.changes b/tcpdump.changes index ba4c983..20beb9d 100644 --- a/tcpdump.changes +++ b/tcpdump.changes @@ -1,3 +1,32 @@ +------------------------------------------------------------------- +Fri Aug 15 19:45:52 UTC 2014 - andreas.stieger@gmx.de + +- tcpdump 4.6.1: + * add a short option '#', same as long option '--number' +- includes changes from 4.6.0: + * all of tcpdump is now using the new "NDO" code base + * nflog, mobile, forces, pptp, AODV, AHCP, IPv6, OSPFv4, RPL, + DHCPv6 enhancements/fixes + * M3UA decode added. + * many new test cases: 82 in 4.5.1 to 133 in 4.6.0 + * cleaned up some unnecessary header files + * Added bittok2str(). + * a number of unaligned access faults fixed + * -A flag does not consider CR to be printable anymore + * fx.lebail took over coverity baby sitting + * default snapshot size increased to 256K for accomodate USB + captures +- includes changes from 4.5.2: + * man page fix +- add build and runtime libpcap minimum version +- remove old patches, thus making package patchless: + tcpdump-4.0.0-prototypes.patch + tcpdump-4.0.0-aliasing.patch +- run spec cleaner on spec file +- remove gpg-offline, now part of source validator +- remove versioned binary +- run regression tests + ------------------------------------------------------------------- Sat Dec 14 11:19:45 UTC 2013 - andreas.stieger@gmx.de diff --git a/tcpdump.spec b/tcpdump.spec index 4e67294..245d141 100644 --- a/tcpdump.spec +++ b/tcpdump.spec @@ -1,7 +1,7 @@ # # spec file for package tcpdump # -# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2014 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 @@ -16,57 +16,53 @@ # +# from http://upstream-tracker.org/versions/libpcap.html +# for pcap_set_tstamp_precision() +%define min_libpcap_version 1.5.1 Name: tcpdump -Version: 4.5.1 +Version: 4.6.1 Release: 0 -Url: http://www.tcpdump.org/ Summary: A Packet Sniffer License: BSD-3-Clause Group: Productivity/Networking/Diagnostic +Url: http://www.tcpdump.org/ Source: http://www.tcpdump.org/release/%{name}-%{version}.tar.gz Source1: tcpdump-qeth Source2: http://www.tcpdump.org/release/%{name}-%{version}.tar.gz.sig Source3: http://www.tcpdump.org/tcpdump-workers.asc#/%{name}.keyring -Patch0: tcpdump-4.0.0-prototypes.patch -Patch2: tcpdump-4.0.0-aliasing.patch -BuildRequires: libpcap-devel +BuildRequires: libpcap-devel >= %{min_libpcap_version} BuildRequires: libsmi-devel BuildRequires: openssl-devel -%if 0%{?suse_version} >= 1230 -BuildRequires: gpg-offline -%endif +Requires: libpcap >= %{min_libpcap_version} 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 -%{?gpg_verify: %gpg_verify %{S:2}} %setup -q -%patch0 -%patch2 %build -export CFLAGS="$RPM_OPT_FLAGS -Wall -DGUESS_TSO -fstack-protector -fno-strict-aliasing" +export CFLAGS="%{optflags} -Wall -DGUESS_TSO -fstack-protector -fno-strict-aliasing" %configure \ --enable-ipv6 -make +make %{?_smp_mflags} %install -make DESTDIR=$RPM_BUILD_ROOT install +make DESTDIR=%{buildroot} install %{?_smp_mflags} %ifarch s390 s390x - install -D -m 755 $RPM_SOURCE_DIR/tcpdump-qeth $RPM_BUILD_ROOT%{_sbindir} + install -D -m 755 ${SOURCE1} %{buildroot}%{_sbindir} %endif +rm %{buildroot}/%{_sbindir}/tcpdump.%{version} -%clean -rm -rf $RPM_BUILD_ROOT +%check +make check %{?_smp_mflags} %files %defattr(-,root,root) %doc CHANGES CREDITS LICENSE README* *.awk %doc %{_mandir}/man?/* -%{_sbindir}/* +%{_sbindir}/tcpdump %changelog