OSDN Git Service

selftests: net: ip_defrag: cover new IPv6 defrag behavior
authorPeter Oskolkov <posk@google.com>
Tue, 22 Jan 2019 18:02:53 +0000 (10:02 -0800)
committerDavid S. Miller <davem@davemloft.net>
Sat, 26 Jan 2019 05:37:11 +0000 (21:37 -0800)
commit4c3510483d26420d2c2c7cc075ad872286cc5932
tree299dc0f94d0626e3f75d61450507135f0892389d
parent997dd96471641e147cb2c33ad54284000d0f5e35
selftests: net: ip_defrag: cover new IPv6 defrag behavior

This patch adds several changes to the ip_defrag selftest, to cover
new IPv6 defrag behavior:

- min IPv6 frag size is now 8 instead of 1280

- new test cases to cover IPv6 defragmentation in nf_conntrack_reasm.c

- new "permissive" mode in negative (overlap) tests: netfilter
sometimes drops invalid packets without passing them to IPv6
underneath, and thus defragmentation sometimes succeeds when
it is expected to fail; so the permissive mode does not fail the
test if the correct reassembled datagram is received instead of a
timeout.

Signed-off-by: Peter Oskolkov <posk@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
tools/testing/selftests/net/ip_defrag.c
tools/testing/selftests/net/ip_defrag.sh