]> git.baikalelectronics.ru Git - kernel.git/commit
[ESP]: Ensure IV is in linear part of the skb to avoid BUG() due to OOB access
authorThomas Graf <tgraf@suug.ch>
Thu, 27 Mar 2008 23:08:03 +0000 (16:08 -0700)
committerDavid S. Miller <davem@davemloft.net>
Thu, 27 Mar 2008 23:08:03 +0000 (16:08 -0700)
commitd7290181956b6931b6471253623b990d906fc37e
tree1de9a439eec25d514f25254320ded076f5fd8144
parent630d1e93b72b726665b1cc17ea3f18223c120641
[ESP]: Ensure IV is in linear part of the skb to avoid BUG() due to OOB access

ESP does not account for the IV size when calling pskb_may_pull() to
ensure everything it accesses directly is within the linear part of a
potential fragment. This results in a BUG() being triggered when the
both the IPv4 and IPv6 ESP stack is fed with an skb where the first
fragment ends between the end of the esp header and the end of the IV.

This bug was found by Dirk Nehring <dnehring@gmx.net> .

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/esp4.c
net/ipv6/esp6.c