]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
[ATM]: Check IP header validity in mpc_send_packet
authorHerbert Xu <herbert@gondor.apana.org.au>
Mon, 21 Jan 2008 00:14:02 +0000 (02:14 +0200)
committerAdrian Bunk <bunk@kernel.org>
Mon, 21 Jan 2008 00:14:02 +0000 (02:14 +0200)
commit4bd7834e412c9f4478f9a17c5f7768d21b87fc63
tree862aec23ea6a486ffc243f961c4abfe6e4f4e100
parentd2c758a5fa26777d955fc2bade9c338d1aed5117
[ATM]: Check IP header validity in mpc_send_packet

[ Upstream commit: 1c9b7aa1eb40ab708ef3242f74b9a61487623168 ]

Al went through the ip_fast_csum callers and found this piece of code
that did not validate the IP header.  While root crashing the machine
by sending bogus packets through raw or AF_PACKET sockets isn't that
serious, it is still nice to react gracefully.

This patch ensures that the skb has enough data for an IP header and
that the header length field is valid.

Adrian Bunk:
Backported to 2.6.16 following instructions by David Miller.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Adrian Bunk <bunk@kernel.org>
net/atm/mpc.c