]> git.baikalelectronics.ru Git - kernel.git/commit
netfilter: nft_reject_bridge: Fix for missing reply from prerouting
authorPhil Sutter <phil@nwl.cc>
Tue, 25 Jan 2022 19:06:03 +0000 (20:06 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Wed, 26 Jan 2022 23:06:52 +0000 (00:06 +0100)
commitfecc345cd5e3227d601df0846f2eb2b5d25df5e8
tree7a0bd5b3aeff3f06f98918220609f2e0893010c1
parent11b3cbf5de299c8475e431f02450eea87d11a8f9
netfilter: nft_reject_bridge: Fix for missing reply from prerouting

Prior to commit f8008ca486554 ("netfilter: nf_reject: add reject skbuff
creation helpers"), nft_reject_bridge did not assign to nskb->dev before
passing nskb on to br_forward(). The shared skbuff creation helpers
introduced in above commit do which seems to confuse br_forward() as
reject statements in prerouting hook won't emit a packet anymore.

Fix this by simply passing NULL instead of 'dev' to the helpers - they
use the pointer for just that assignment, nothing else.

Fixes: f8008ca486554 ("netfilter: nf_reject: add reject skbuff creation helpers")
Signed-off-by: Phil Sutter <phil@nwl.cc>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
net/bridge/netfilter/nft_reject_bridge.c