]> git.baikalelectronics.ru Git - kernel.git/commit
ipv6: Fix IPsec pre-encap fragmentation check
authorHerbert Xu <herbert@gondor.apana.org.au>
Fri, 4 Sep 2015 05:21:06 +0000 (13:21 +0800)
committerSteffen Klassert <steffen.klassert@secunet.com>
Fri, 4 Sep 2015 07:02:59 +0000 (09:02 +0200)
commit0078c350287f9367cbaa72f4cd43b0af2f2966e4
tree8c4656a196b9980fdf82788595c0324254b90a97
parent4d629f6230087d2e1b3b2e1017304195b6e1e9ff
ipv6: Fix IPsec pre-encap fragmentation check

The IPv6 IPsec pre-encap path performs fragmentation for tunnel-mode
packets.  That is, we perform fragmentation pre-encap rather than
post-encap.

A check was added later to ensure that proper MTU information is
passed back for locally generated traffic.  Unfortunately this
check was performed on all IPsec packets, including transport-mode
packets.

What's more, the check failed to take GSO into account.

The end result is that transport-mode GSO packets get dropped at
the check.

This patch fixes it by moving the tunnel mode check forward as well
as adding the GSO check.

Fixes: 3d35eedfac15 ("xfrm6: Don't call icmpv6_send on local error")
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
net/ipv6/xfrm6_output.c