]> git.baikalelectronics.ru Git - kernel.git/commit
tcp: Add a tcp_filter hook before handle ack packet
authorChenbo Feng <fengc@google.com>
Wed, 21 Jun 2017 02:06:40 +0000 (19:06 -0700)
committerDavid S. Miller <davem@davemloft.net>
Thu, 22 Jun 2017 15:13:56 +0000 (11:13 -0400)
commit9b15d20d67e6a236dc3bd8be8d8c4a33b8ae5699
treee8e8a7d3fdf70628d174f346c1bcf215b545f450
parent4a2ee6b039350c8958b111be22b6c87d1d26e27e
tcp: Add a tcp_filter hook before handle ack packet

Currently in both ipv4 and ipv6 code path, the ack packet received when
sk at TCP_NEW_SYN_RECV state is not filtered by socket filter or cgroup
filter since it is handled from tcp_child_process and never reaches the
tcp_filter inside tcp_v4_rcv or tcp_v6_rcv. Adding a tcp_filter hooks
here can make sure all the ingress tcp packet can be correctly filtered.

Signed-off-by: Chenbo Feng <fengc@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/tcp_ipv4.c
net/ipv6/tcp_ipv6.c