l2tp: test for ethernet header in l2tp_eth_dev_recv()
commit2974d51279e5437f5b34a5163d1d835586488946
authorEric Dumazet <eric.dumazet@gmail.com>
Wed, 25 Aug 2010 23:44:35 +0000 (25 23:44 +0000)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 27 Sep 2010 00:18:15 +0000 (26 17:18 -0700)
tree354cc832c12f4848bbf7c34083721641afddd4b9
parent4aeda42a1b443d705980c85184cca7f8f28625bf
l2tp: test for ethernet header in l2tp_eth_dev_recv()

[ Upstream commit bfc960a8eec023a170a80697fe65157cd4f44f81 ]

close https://bugzilla.kernel.org/show_bug.cgi?id=16529

Before calling dev_forward_skb(), we should make sure skb head contains
at least an ethernet header, even if length included in upper layer said
so. Use pskb_may_pull() to make sure this ethernet header is present in
skb head.

Reported-by: Thomas Heil <heil@terminal-consulting.de>
Reported-by: Ian Campbell <Ian.Campbell@eu.citrix.com>
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
net/l2tp/l2tp_eth.c