Skip to content

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

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

cron2
Copy link

@cron2 cron2 commented Jul 1, 2025

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 #810

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#810
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant