]> www.infradead.org Git - users/dwmw2/linux.git/commit
netfilter: nft_limit: Clone packet limits' cost value
authorPhil Sutter <phil@nwl.cc>
Tue, 24 May 2022 12:50:01 +0000 (14:50 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 6 Jun 2022 06:48:54 +0000 (08:48 +0200)
commita51c6c58ce940db65100bbfd58189b49d9da1f27
tree1ac62bbae3a03e3d907aaa89c350eb1978359782
parent2193286402df2d9c53294f7a858d5e6fd7346e08
netfilter: nft_limit: Clone packet limits' cost value

commit 558254b0b602b8605d7246a10cfeb584b1fcabfc upstream.

When cloning a packet-based limit expression, copy the cost value as
well. Otherwise the new limit is not functional anymore.

Fixes: 3b9e2ea6c11bf ("netfilter: nft_limit: move stateful fields out of expression data")
Signed-off-by: Phil Sutter <phil@nwl.cc>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/netfilter/nft_limit.c