]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
netfilter: ctnetlink: use nf_ct_exp_net() in expectation dump
authorPratham Gupta <pratham36gupta@gmail.com>
Tue, 5 May 2026 05:11:57 +0000 (22:11 -0700)
committerFlorian Westphal <fw@strlen.de>
Sun, 24 May 2026 20:55:47 +0000 (22:55 +0200)
commita7f57320bbbc67e347bf5fff4b4a9bab980d5956
tree7f94120ec47e78c0a8f40c6976c900ecce190890
parente9fd2fb09cfe4abb5c6238141ffbbfcb4a01aa4b
netfilter: ctnetlink: use nf_ct_exp_net() in expectation dump

Commit 02a3231b6d82 ("netfilter: nf_conntrack_expect: store netns and zone in expectation")
introduced exp->net so RCU-only expectation paths no longer need to
dereference exp->master for netns lookups.

Commit 3db5647984de ("netfilter: nf_conntrack_expect: skip expectations in other netns via proc")
updated the proc path accordingly, but ctnetlink_exp_dump_table() still
compares against nf_ct_net(exp->master).

Use nf_ct_exp_net(exp) here as well so the netlink dump path matches
the rest of the March 2026 expectation netns/RCU cleanup.

Fixes: 02a3231b6d82 ("netfilter: nf_conntrack_expect: store netns and zone in expectation")
Cc: stable@vger.kernel.org
Signed-off-by: Pratham Gupta <pratham36gupta@gmail.com>
Signed-off-by: Florian Westphal <fw@strlen.de>
net/netfilter/nf_conntrack_netlink.c