tcpdump icon indicating copy to clipboard operation
tcpdump copied to clipboard

print-ip6.c: make '-v' output similar to print-ip.c

Open cron2 opened this issue 5 months ago • 0 comments

This changes the output for IPv6 packets from "everything in one line, and the length printed is the payload length only" to a two-line format, which has the overall packet length in the first line, and the payload length in the second line.

The old '-v' format printed everything in one line, with only the payload length at a different place, suppressing the payload length for ICMPv6 packets - so this check is removed, we intentionally print two length fields like for IPv4. This is helpful when trying to be really sure about packet sizes when debugging MTU issues etc.

The actual code change is very small but the commit is huge as a large number of test cases are affected.

The new '-g' option is taken into account as well.

Github: implements the-tcpdump-group/tcpdump#810

cron2 avatar Jul 01 '25 14:07 cron2