]> The Tcpdump Group git mirrors - tcpdump/commitdiff
LMP: Add a test capture file
authorFrancois-Xavier Le Bail <[email protected]>
Wed, 23 Oct 2019 08:01:48 +0000 (10:01 +0200)
committerFrancois-Xavier Le Bail <[email protected]>
Wed, 23 Oct 2019 08:01:48 +0000 (10:01 +0200)
This capture file triggered a buffer over-read with the 4.9.2 release
fixed in the 4.9.3 release.

With the new GET_ macros, the problem no longer exists.
Thus no fix needed.

The pcap file was updated to pass the sanity checks, keep only the
relevant packets and avoid pcap_loop() error messages.

Update the output of the test accordingly.

Partial update from d97e94223720684c6aa740ff219e0d19426c2220
in 4.9 branch.

tests/TESTLIST
tests/lmp-lmp_print_data_link_subobjs-oobr.out [new file with mode: 0644]
tests/lmp-lmp_print_data_link_subobjs-oobr.pcap [new file with mode: 0644]

index 654cb4e1b8de81f87c29ae2ccbdadeeeede72593..df4b61bb052021c8ef3274d1e14ce64161280951 100644 (file)
@@ -613,6 +613,7 @@ vrrp-vrrp_print-oobr vrrp-vrrp_print-oobr.pcap vrrp-vrrp_print-oobr.out -v
 vrrp-vrrp_print-oobr-2 vrrp-vrrp_print-oobr-2.pcap vrrp-vrrp_print-oobr-2.out -v
 bgp-bgp_capabilities_print-oobr-1 bgp-bgp_capabilities_print-oobr-1.pcap bgp-bgp_capabilities_print-oobr-1.out -v
 bgp-bgp_capabilities_print-oobr-2 bgp-bgp_capabilities_print-oobr-2.pcap bgp-bgp_capabilities_print-oobr-2.out -v
+lmp-lmp_print_data_link_subobjs-oobr lmp-lmp_print_data_link_subobjs-oobr.pcap lmp-lmp_print_data_link_subobjs-oobr.out -v
 # The .pcap file is truncated after the 1st packet.
 hncp_dhcpv6data-oobr   hncp_dhcpv6data-oobr.pcap       hncp_dhcpv6data-oobr.out -v -c1
 hncp_dhcpv4data-oobr   hncp_dhcpv4data-oobr.pcap       hncp_dhcpv4data-oobr.out -v -c1
diff --git a/tests/lmp-lmp_print_data_link_subobjs-oobr.out b/tests/lmp-lmp_print_data_link_subobjs-oobr.out
new file mode 100644 (file)
index 0000000..f7b87a6
--- /dev/null
@@ -0,0 +1,20 @@
+    1  06:58:21.3858891542 IP (tos 0xfd,ECT(1), ttl 254, id 45839, offset 0, flags [+, DF, rsvd], proto UDP (17), length 56871, bad cksum fe07 (->ddf0)!)
+    17.8.8.255.701 > 40.184.42.8.12: 
+       LMPv1, msg-type: unknown, type: 249, Flags: [none], length: 212
+         Data Link Object (12), Class-Type: Unnumbered (3) Flags: [non-negotiable], length: 20
+           Flags: [none]
+           Local Interface ID: 2435832538 (0x912fdada)
+           Remote Interface ID: 3657433088 (0xda000000)
+           Subobject, Type: Interface Switching Type (1), Length: 4
+             Switching Type: Unknown (0)
+             Encoding Type: Unknown (0) [|lmp]
+    2  00:02:08.1114902 IP (tos 0xfd,ECT(1), ttl 254, id 45839, offset 0, flags [+, DF, rsvd], proto UDP (17), length 56871, bad cksum fe07 (->ddf0)!)
+    17.8.8.255.701 > 40.184.42.8.12: 
+       LMPv1, msg-type: unknown, type: 249, Flags: [none], length: 212
+         Data Link Object (12), Class-Type: Unnumbered (3) Flags: [non-negotiable], length: 20
+           Flags: [none]
+           Local Interface ID: 2435832538 (0x912fdada)
+           Remote Interface ID: 3657433088 (0xda000000)
+           Subobject, Type: Interface Switching Type (1), Length: 4
+             Switching Type: Unknown (0)
+             Encoding Type: Unknown (0) [|lmp]
diff --git a/tests/lmp-lmp_print_data_link_subobjs-oobr.pcap b/tests/lmp-lmp_print_data_link_subobjs-oobr.pcap
new file mode 100644 (file)
index 0000000..661d9bd
Binary files /dev/null and b/tests/lmp-lmp_print_data_link_subobjs-oobr.pcap differ