]> git.baikalelectronics.ru Git - kernel.git/commit
netfilter: check if the socket netns is correct.
authorFlavio Leitner <fbl@redhat.com>
Wed, 27 Jun 2018 13:34:25 +0000 (10:34 -0300)
committerDavid S. Miller <davem@davemloft.net>
Thu, 28 Jun 2018 13:21:32 +0000 (22:21 +0900)
commit45b00f6a8b3ca6599968f9e149925aa0d48c9286
tree5bc5ca2ef701a097f0447a7073c2ee0be9b79e01
parent7e860af5a30a2ea8b70d14f9f69154723c18bccc
netfilter: check if the socket netns is correct.

Netfilter assumes that if the socket is present in the skb, then
it can be used because that reference is cleaned up while the skb
is crossing netns.

We want to change that to preserve the socket reference in a future
patch, so this is a preparation updating netfilter to check if the
socket netns matches before use it.

Signed-off-by: Flavio Leitner <fbl@redhat.com>
Acked-by: Florian Westphal <fw@strlen.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
12 files changed:
include/net/netfilter/nf_log.h
net/ipv4/netfilter/nf_log_ipv4.c
net/ipv6/netfilter/nf_log_ipv6.c
net/netfilter/nf_conntrack_broadcast.c
net/netfilter/nf_log_common.c
net/netfilter/nf_nat_core.c
net/netfilter/nft_meta.c
net/netfilter/nft_socket.c
net/netfilter/xt_cgroup.c
net/netfilter/xt_owner.c
net/netfilter/xt_recent.c
net/netfilter/xt_socket.c