OSDN Git Service

netfilter: ctnetlink: fix dump of the expect mask attribute
authorFlorian Westphal <fw@strlen.de>
Mon, 15 Mar 2021 10:31:09 +0000 (11:31 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Mon, 15 Mar 2021 17:42:01 +0000 (18:42 +0100)
commitb58f33d49e426dc66e98ed73afb5d97b15a25f2d
tree05715047243687468325285cd018c7e3713d355e
parent175e476b8cdf2a4de7432583b49c871345e4f8a1
netfilter: ctnetlink: fix dump of the expect mask attribute

Before this change, the mask is never included in the netlink message, so
"conntrack -E expect" always prints 0.0.0.0.

In older kernels the l3num callback struct was passed as argument, based
on tuple->src.l3num. After the l3num indirection got removed, the call
chain is based on m.src.l3num, but this value is 0xffff.

Init l3num to the correct value.

Fixes: f957be9d349a3 ("netfilter: conntrack: remove ctnetlink callbacks from l3 protocol trackers")
Signed-off-by: Florian Westphal <fw@strlen.de>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
net/netfilter/nf_conntrack_netlink.c