IPv6: Fix inconsistencies in the printing of some option names
1) Hop-by-Hop Options Header
$ ./tcpdump --skip 1 -c1 -tnv -r tests/icmpv6.pcap
Before:
IP6 (hlim 1, next-header Options (0), payload length 36)
fe80::215:17ff:fecc:e546 > ff02::16: HBH (rtalert: 0x0000) (padn)
[icmp6 sum ok] ICMP6, [...]
There is "next-header Options" but the next header is printed "HBH".
After:
IP6 (hlim 1, next-header HBH (0), payload length 36)
fe80::215:17ff:fecc:e546 > ff02::16: HBH (rtalert: 0x0000) (padn)
[icmp6 sum ok] ICMP6, [...]
2) Destination Options Header
$ ./tcpdump -tnv -r tests/erspan-type-iii-pb-1.pcap
Before:
IP6 (class 0x30, flowlabel 0x00001, hlim 1, next-header unknown (60),
payload length 288) 4120:7467:1700:4200:143:100:7f01:400e >
4591:bfd7:cd87:d7:68:38:101:e800: DSTOPT (padn) [...]
There is "next-header unknown" but next header is printed "DSTOPT".
After:
IP6 (class 0x30, flowlabel 0x00001, hlim 1, next-header DSTOPT (60),
payload length 288) 4120:7467:1700:4200:143:100:7f01:400e >
4591:bfd7:cd87:d7:68:38:101:e800: DSTOPT (padn) [...]
Moreover:
Update a ndo_protocol (s/hbhopt/hbh/).
Use nd_print_protocol_caps().
Update some test outputs accordingly.
(backported from commit
803b7028e04b757c5351a300a905e326c7d5a200)