]> git.baikalelectronics.ru Git - kernel.git/commit
tcp: Fix slab corruption with ipv6 and tcp6fuzz
authorEvgeniy Polyakov <johnpol@2ka.mipt.ru>
Sun, 27 Apr 2008 22:27:30 +0000 (15:27 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sun, 27 Apr 2008 22:27:30 +0000 (15:27 -0700)
commit38c7e1a84f117c8871fd613e033d75831c2cd2ed
tree54ef2bb504625e003a35dae8ebbeb4b755f52419
parentd1324ca3061d0d4593490beb8b7b4c0569df96d1
tcp: Fix slab corruption with ipv6 and tcp6fuzz

From: Evgeniy Polyakov <johnpol@2ka.mipt.ru>

This fixes a regression added by 2209240bb94ab377cd508df38e13e2ddc2dc8585
("[TCP]: TCP_DEFER_ACCEPT updates - process as established")

tcp_v6_do_rcv()->tcp_rcv_established(), the latter goes to step5, where
eventually skb can be freed via tcp_data_queue() (drop: label), then if
check for tcp_defer_accept_check() returns true and thus
tcp_rcv_established() returns -1, which forces tcp_v6_do_rcv() to jump
to reset: label, which in turn will pass through discard: label and free
the same skb again.

Tested by Eric Sesterhenn.

Signed-off-by: David S. Miller <davem@davemloft.net>
Acked-By: Patrick McManus <mcmanus@ducksong.com>
net/ipv4/tcp_input.c