Skip to content

Commit

Permalink
selftest/bpf: fix IPV6FR handling in flow dissector
Browse files Browse the repository at this point in the history
>From second fragment on, IPV6FR program must stop the dissection of IPV6
fragmented packet. This is the same approach used for IPV4 fragmentation.

Signed-off-by: Santucci Pierpaolo <santucci@epigenesys.com>
  • Loading branch information
Santucci Pierpaolo authored and kernel-patches-bot committed Nov 10, 2020
1 parent ab3e38a commit 95eb946
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tools/testing/selftests/bpf/progs/bpf_flow.c
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,8 @@ PROG(IPV6FR)(struct __sk_buff *skb)
*/
if (!(keys->flags & BPF_FLOW_DISSECTOR_F_PARSE_1ST_FRAG))
return export_flow_keys(keys, BPF_OK);
} else {
return export_flow_keys(keys, BPF_OK);
}

return parse_ipv6_proto(skb, fragh->nexthdr);
Expand Down

0 comments on commit 95eb946

Please sign in to comment.