xfrm6: Fix ICMPv6 and MH header checks in _decode_session6
authorMathias Krause <mathias.krause@secunet.com>
Fri, 11 Sep 2015 07:57:20 +0000 (09:57 +0200)
committerSteffen Klassert <steffen.klassert@secunet.com>
Mon, 14 Sep 2015 08:53:05 +0000 (10:53 +0200)
commit04a6b8bfee06e309be7e9ae4527cdab19c081761
tree82e72d3ed231222243487b575887c2b974025a6d
parent93efac3f2e03321129de67a3c0ba53048bb53e31
xfrm6: Fix ICMPv6 and MH header checks in _decode_session6

Ensure there's enough data left prior calling pskb_may_pull(). If
skb->data was already advanced, we'll call pskb_may_pull() with a
negative value converted to unsigned int -- leading to a huge
positive value. That won't matter in practice as pskb_may_pull()
will likely fail in this case, but it leads to underflow reports on
kernels handling such kind of over-/underflows, e.g. a PaX enabled
kernel instrumented with the size_overflow plugin.

Reported-by: satmd <satmd@lain.at>
Reported-and-tested-by: Marcin Jurkowski <marcin1j@gmail.com>
Signed-off-by: Mathias Krause <mathias.krause@secunet.com>
Cc: PaX Team <pageexec@freemail.hu>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
net/ipv6/xfrm6_policy.c
This page took 0.024131 seconds and 5 git commands to generate.