diff options
author | John Helmert III <jchelmert3@posteo.net> | 2020-11-04 01:09:03 -0600 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2020-11-05 14:08:01 +0000 |
commit | 75f0ee948825fc1dd8060a4480a0dd5872424313 (patch) | |
tree | da2171bdcb774a89c1ebd312d0b67cb80b05ca5b /net-libs/nDPI | |
parent | sys-libs/timezone-data: remove myself as a maintainer (diff) | |
download | gentoo-75f0ee948825fc1dd8060a4480a0dd5872424313.tar.gz gentoo-75f0ee948825fc1dd8060a4480a0dd5872424313.tar.bz2 gentoo-75f0ee948825fc1dd8060a4480a0dd5872424313.zip |
net-libs/nDPI: bump to 3.4
Bug: https://bugs.gentoo.org/719084
Package-Manager: Portage-3.0.9, Repoman-3.0.2
Signed-off-by: John Helmert III <jchelmert3@posteo.net>
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'net-libs/nDPI')
-rw-r--r-- | net-libs/nDPI/Manifest | 1 | ||||
-rw-r--r-- | net-libs/nDPI/files/nDPI-3.4-fix-oob-in-kerberos-dissector.patch | 16 | ||||
-rw-r--r-- | net-libs/nDPI/nDPI-3.4.ebuild | 63 |
3 files changed, 80 insertions, 0 deletions
diff --git a/net-libs/nDPI/Manifest b/net-libs/nDPI/Manifest index ff887adc5eb0..11430d2ded9a 100644 --- a/net-libs/nDPI/Manifest +++ b/net-libs/nDPI/Manifest @@ -3,3 +3,4 @@ DIST nDPI-2.2.tar.gz 19937173 BLAKE2B a00287d5901487f7e56d7aeab7dcb357c0eb6348be DIST nDPI-2.8.tar.gz 19754226 BLAKE2B c112ae2d9fff872f116a23bbffe7bca39a5c876346b4e41ef503934301f39413517fce169a37a766ffae16b0cb1ee81d96573ffa1ee2519d295dfb32cc1f115e SHA512 aae757047810bbc32700ecf7ac2e5df4b93528021a50da4a0b83865a5248dfca8b1643c75aa7eeb6eac4f155638d45666db487318b2be9adb2f3412cb8ec8497 DIST nDPI-3.0.tar.gz 26902734 BLAKE2B 79380ce5138b8ba99169ce3a2afeaa2a2bcded9bc7834d32af6911e9cee60395613a390d2d5d0530b9ff9263ad707e78f49d35098428c66a9c95a98aee2d8df8 SHA512 74c4a41201e809b476f4c23b99c2391b7bcbc76507a11261d216caf2350db8fd4ae3dac69d1d2179b12217901da1e04676aeca05d3a8e63d1a162469b33ab4c0 DIST nDPI-3.2.tar.gz 29586049 BLAKE2B 4ea7f1cf39b5363b724c2db84c006de2f0e05ea275586241c3e1b9a53681f1da83dc752e69d379d6b8c8bcf8b15b146e8a2de127931d3b2061112aef297f7d79 SHA512 bf3a6e66479110b8e1a51a3b66cc0a85aef98af455f2895a75fe2a8b06a9fb72a4dca3d4bbfa6f44959c5043c038927a1a8acb312e881d4e2bb544dc84b6eea8 +DIST nDPI-3.4.tar.gz 37976087 BLAKE2B 49e25586671a91278d90775c3dbc881ce4ca9ae4afd3108b1caff3b0d38251808bcd52ead253f451474195994fbf94658f70241acedb23c35a475df3b15c4a20 SHA512 ed5a22b6ddc14ad707a18a0bd96746c1df489969faaa42016fa9aad8d414fc4ee303b96cac15c3ba86f484a80a0aaa2dd1be5f92be672912e0e0d30da4bdad4c diff --git a/net-libs/nDPI/files/nDPI-3.4-fix-oob-in-kerberos-dissector.patch b/net-libs/nDPI/files/nDPI-3.4-fix-oob-in-kerberos-dissector.patch new file mode 100644 index 000000000000..7e8f381cdeab --- /dev/null +++ b/net-libs/nDPI/files/nDPI-3.4-fix-oob-in-kerberos-dissector.patch @@ -0,0 +1,16 @@ +Sourced from https://github.com/gentoo/gentoo/commit/c02681fcb7839ac1829ec09394334ddbca1b0aea + +diff --git a/src/lib/protocols/kerberos.c b/src/lib/protocols/kerberos.c +index fa0ab6cb..32319668 100644 +--- a/src/lib/protocols/kerberos.c ++++ b/src/lib/protocols/kerberos.c +@@ -189,7 +189,8 @@ void ndpi_search_kerberos(struct ndpi_detection_module_struct *ndpi_struct, + + body_offset = koffsetp + 1 + pad_len; + +- for(i=0; i<10; i++) if(body_offset<packet->payload_packet_len && packet->payload[body_offset] != 0x05) body_offset++; /* ASN.1 */ ++ for(i=0; i<10 && body_offset < packet->payload_packet_len; i++) ++ if(packet->payload[body_offset] != 0x05) body_offset++; /* ASN.1 */ + #ifdef KERBEROS_DEBUG + printf("body_offset=%u [%02X %02X] [byte 0 must be 0x05]\n", body_offset, packet->payload[body_offset], packet->payload[body_offset+1]); + #endif diff --git a/net-libs/nDPI/nDPI-3.4.ebuild b/net-libs/nDPI/nDPI-3.4.ebuild new file mode 100644 index 000000000000..39a1a4c8a57d --- /dev/null +++ b/net-libs/nDPI/nDPI-3.4.ebuild @@ -0,0 +1,63 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit autotools + +DESCRIPTION="Open Source Deep Packet Inspection Software Toolkit" +HOMEPAGE="https://www.ntop.org/" +SRC_URI="https://github.com/ntop/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="LGPL-3+" +SLOT="0/$(ver_cut 1)" +KEYWORDS="~amd64 ~x86" + +DEPEND="dev-libs/json-c:= + net-libs/libpcap" +RDEPEND="${DEPEND}" + +PATCHES=( + "${FILESDIR}/${PN}-3.4-fix-oob-in-kerberos-dissector.patch" +) + +src_prepare() { + eval $(grep '^NDPI_MAJOR=' autogen.sh) + eval $(grep '^NDPI_MINOR=' autogen.sh) + eval $(grep '^NDPI_PATCH=' autogen.sh) + NDPI_VERSION_SHORT="${NDPI_MAJOR}.${NDPI_MINOR}.${NDPI_PATCH}" + + sed \ + -e "s/@NDPI_MAJOR@/${NDPI_MAJOR}/g" \ + -e "s/@NDPI_MINOR@/${NDPI_MINOR}/g" \ + -e "s/@NDPI_PATCH@/${NDPI_PATCH}/g" \ + -e "s/@NDPI_VERSION_SHORT@/${NDPI_VERSION_SHORT}/g" \ + -e "s/@FUZZY@//g" \ + < "${S}/configure.seed" \ + > "${S}/configure.ac" || die + + sed -i \ + -e "s%^libdir\s*=\s*\${prefix}/lib\s*$%libdir = \${prefix}/$(get_libdir)%" \ + src/lib/Makefile.in || die + + default + eautoreconf + + # Taken from autogen.sh (bug #704074): + sed -i \ + -e "s/#define PACKAGE/#define NDPI_PACKAGE/g" \ + -e "s/#define VERSION/#define NDPI_VERSION/g" \ + configure || die +} + +src_install() { + default + rm "${D}"/usr/$(get_libdir)/lib${PN,,}.a || die +} + +src_test() { + pushd tests || die + ./do.sh || die "Failed tests" + ./do-unit.sh || die "Failed tests" + popd || die +} |