diff --git a/SOURCES/0001-pcap-linux-don-t-use-TPACKETV3-for-memory-mmapped-ca.patch b/SOURCES/0001-pcap-linux-don-t-use-TPACKETV3-for-memory-mmapped-ca.patch new file mode 100644 index 0000000..ced452a --- /dev/null +++ b/SOURCES/0001-pcap-linux-don-t-use-TPACKETV3-for-memory-mmapped-ca.patch @@ -0,0 +1,34 @@ +From b298835b3e4e918f00315f3a4e33e73c031ce98e Mon Sep 17 00:00:00 2001 +From: rpm-build +Date: Wed, 5 Nov 2014 07:41:11 +0100 +Subject: [PATCH] pcap-linux: don't use TPACKETV3 for memory mmapped capture + +There has been numerous reports from users complaining about changes in behavior +of libpcap when using libpcap compiled with TPACKETV3 support. Back out and +disable it. + +See: https://github.com/the-tcpdump-group/libpcap/issues/380 +See: https://github.com/the-tcpdump-group/libpcap/issues/364 + +Resolves: #1085096 +--- + pcap-linux.c | 3 --- + 1 file changed, 3 deletions(-) + +diff --git a/pcap-linux.c b/pcap-linux.c +index 83bb107..117405b 100644 +--- a/pcap-linux.c ++++ b/pcap-linux.c +@@ -198,9 +198,6 @@ static const char rcsid[] _U_ = + * uses many ring related structs and macros */ + # ifdef TPACKET_HDRLEN + # define HAVE_PACKET_RING +-# ifdef TPACKET3_HDRLEN +-# define HAVE_TPACKET3 +-# endif /* TPACKET3_HDRLEN */ + # ifdef TPACKET2_HDRLEN + # define HAVE_TPACKET2 + # else /* TPACKET2_HDRLEN */ +-- +1.8.3.1 + diff --git a/SPECS/libpcap.spec b/SPECS/libpcap.spec index 9f8c7cf..02f703b 100644 --- a/SPECS/libpcap.spec +++ b/SPECS/libpcap.spec @@ -1,7 +1,7 @@ Name: libpcap Epoch: 14 Version: 1.5.3 -Release: 3%{?dist} +Release: 3%{?dist}.1 Summary: A system-independent interface for user-level packet capture Group: Development/Libraries License: BSD with advertising @@ -13,6 +13,7 @@ Patch1: libpcap-man.patch Patch2: libpcap-multilib.patch Patch3: libpcap-s390.patch Patch4: 0001-NFLOG-don-t-crash-trying-to-filter-at-link-layer.patch +Patch5: 0001-pcap-linux-don-t-use-TPACKETV3-for-memory-mmapped-ca.patch %description Libpcap provides a portable framework for low-level network @@ -81,6 +82,9 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libpcap.a %{_mandir}/man5/pcap*.5* %changelog +* Tue Dec 2 2014 Michal Sekletar - 14:1.5.3-3.1 +- disable TPACKET_V3 memory mapped packet capture on AF_PACKET socket, use TPACKET_V2 instead (#1169773) + * Thu Feb 13 2014 Michal Sekletar - 14:1.5.3-3 - don't crash when trying to filter on interface with NFLOG link layer type (#1062511)