diff options
author | Baptiste Daroussin <bapt@FreeBSD.org> | 2020-10-01 14:42:38 +0000 |
---|---|---|
committer | Baptiste Daroussin <bapt@FreeBSD.org> | 2020-10-01 14:42:38 +0000 |
commit | 4ce56818b07cb5aef80c1b3bee3059245536753e (patch) | |
tree | d1de6735794bfc6c0e3c40730d435018ada0ead3 /net/ngrep | |
parent | cd381044d9df2d51a1ea1ca155c4719a93b2688d (diff) | |
download | ports-4ce56818b07cb5aef80c1b3bee3059245536753e.tar.gz ports-4ce56818b07cb5aef80c1b3bee3059245536753e.zip |
Notes
Diffstat (limited to 'net/ngrep')
-rw-r--r-- | net/ngrep/Makefile | 2 | ||||
-rw-r--r-- | net/ngrep/files/patch-fix-ipv6 | 39 |
2 files changed, 40 insertions, 1 deletions
diff --git a/net/ngrep/Makefile b/net/ngrep/Makefile index e09741edd195..8db3f0887938 100644 --- a/net/ngrep/Makefile +++ b/net/ngrep/Makefile @@ -3,7 +3,7 @@ PORTNAME= ngrep PORTVERSION= 1.45 -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= net security MASTER_SITES= SF diff --git a/net/ngrep/files/patch-fix-ipv6 b/net/ngrep/files/patch-fix-ipv6 new file mode 100644 index 000000000000..c7db09f43bf0 --- /dev/null +++ b/net/ngrep/files/patch-fix-ipv6 @@ -0,0 +1,39 @@ +--- ngrep.c 2010-04-21 12:16:52.000000000 +0200 ++++ ngrep.c 2010-04-21 12:11:49.581088102 +0200 +@@ -711,10 +711,12 @@ void process(u_char *d, struct pcap_pkth + data = (unsigned char *)(tcp_pkt) + tcphdr_offset; + len -= link_offset + ip_hl + tcphdr_offset; + ++/* + #if USE_IPv6 + if (ip_ver == 6) + len -= ntohs(ip6_pkt->ip6_plen); +-#endif ++#endif ++*/ + + if ((int32_t)len < 0) + len = 0; +@@ -731,11 +733,12 @@ void process(u_char *d, struct pcap_pkth + data = (unsigned char *)(udp_pkt) + udphdr_offset; + len -= link_offset + ip_hl + udphdr_offset; + ++/* + #if USE_IPv6 + if (ip_ver == 6) + len -= ntohs(ip6_pkt->ip6_plen); + #endif +- ++*/ + if ((int32_t)len < 0) + len = 0; + +@@ -769,7 +772,7 @@ void process(u_char *d, struct pcap_pkth + uint16_t icmp6hdr_offset = (frag_offset) ? 0 : 4; + + data = (unsigned char *)(icmp6_pkt) + icmp6hdr_offset; +- len -= link_offset + ip_hl + ntohs(ip6_pkt->ip6_plen) + icmp6hdr_offset; ++ len -= link_offset + ip_hl + icmp6hdr_offset; + + if ((int32_t)len < 0) + len = 0; |