]> git.baikalelectronics.ru Git - kernel.git/commit
netfilter: conntrack: skip identical origin tuple in same zone only
authorFlorian Westphal <fw@strlen.de>
Fri, 5 Feb 2021 11:56:43 +0000 (12:56 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Mon, 8 Feb 2021 23:04:14 +0000 (00:04 +0100)
commit720e66ff1c10539487e2a82666f72c4888090d05
tree1f35dd93ba3f633448b4bff33ca7e6005247f063
parent5e43bd75ea970bbac579f796fc8b9743ad039a3b
netfilter: conntrack: skip identical origin tuple in same zone only

The origin skip check needs to re-test the zone. Else, we might skip
a colliding tuple in the reply direction.

This only occurs when using 'directional zones' where origin tuples
reside in different zones but the reply tuples share the same zone.

This causes the new conntrack entry to be dropped at confirmation time
because NAT clash resolution was elided.

Fixes: 295e1d854a32214 ("netfilter: nf_nat: skip nat clash resolution for same-origin entries")
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
net/netfilter/nf_conntrack_core.c