]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
netfilter: nf_tables: reject element expiration with no timeout
authorPablo Neira Ayuso <pablo@netfilter.org>
Mon, 2 Sep 2024 23:06:49 +0000 (01:06 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 17 Oct 2024 13:10:44 +0000 (15:10 +0200)
commitb987e863cfd9f6ab67d1847bb66f3a88a8a7c0ac
tree3aeb5e5b6b7022400b04b4e4044765fe7ae52a73
parent616aa2873969feb4e701baa72acf7306b2601e3e
netfilter: nf_tables: reject element expiration with no timeout

[ Upstream commit d2dc429ecb4e79ad164028d965c00f689e6f6d06 ]

If element timeout is unset and set provides no default timeout, the
element expiration is silently ignored, reject this instead to let user
know this is unsupported.

Also prepare for supporting timeout that never expire, where zero
timeout and expiration must be also rejected.

Fixes: 8e1102d5a159 ("netfilter: nf_tables: support timeouts larger than 23 days")
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/netfilter/nf_tables_api.c