Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

selftest/bpf: Fix IPV6FR handling in flow dissector

From second fragment on, IPV6FR program must stop the dissection of IPV6
fragmented packet. This is the same approach used for IPV4 fragmentation.
This fixes the flow keys calculation for the upper-layer protocols.
Note that according to RFC8200, the first fragment packet must include
the upper-layer header.

Signed-off-by: Santucci Pierpaolo <santucci@epigenesys.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Reviewed-by: Jakub Sitnicki <jakub@cloudflare.com>
Link: https://lore.kernel.org/bpf/X7JUzUj34ceE2wBm@santucci.pierpaolo

authored by

Santucci Pierpaolo and committed by
Daniel Borkmann
024cd2cb 2d38c580

+2
+2
tools/testing/selftests/bpf/progs/bpf_flow.c
··· 368 368 */ 369 369 if (!(keys->flags & BPF_FLOW_DISSECTOR_F_PARSE_1ST_FRAG)) 370 370 return export_flow_keys(keys, BPF_OK); 371 + } else { 372 + return export_flow_keys(keys, BPF_OK); 371 373 } 372 374 373 375 return parse_ipv6_proto(skb, fragh->nexthdr);