Skip to contentSkip to conversation

netfilter: egress: Report interface as outgoing

PATCH In review Phil Sutter 2 participants 2 messages Mar 24, 2022 netfilter

lore
Share & tools
lore

Phil Sutter

author reviewer
#0 lore raw

PATCH 1/1 netfilter: egress: Report interface as outgoing

Otherwise packets in egress chains seem like they are being received by the interface, not sent out via it.

Fixes 42df6e1d221dd ("netfilter: Introduce egress hook")
---
 include/linux/netfilter_netdev.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/netfilter_netdev.h +1 -1
index e6487a6911360..8676316547cc4 100644
@@ -99,7 +99,7 @@ static inline struct sk_buff *nf_hook_egress(struct sk_buff *skb, int *rc,
 		return skb;
 
 	nf_hook_state_init(&state, NF_NETDEV_EGRESS,
-			   NFPROTO_NETDEV, dev, NULL, NULL,
+			   NFPROTO_NETDEV, NULL, dev, NULL,
 			   dev_net(dev), NULL);
 
 	/* nf assumes rcu_read_lock, not just read_lock_bh */
Signature · 1 line
2.34.1
maintainer
#1 lore raw
Quoted 2 lines · Phil Sutter

Otherwise packets in egress chains seem like they are being received by the interface, not sent out via it.

Good catch, applied.