]> 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>
Fri, 4 Oct 2024 14:28:53 +0000 (16:28 +0200)
commit2a5e648a0cb682181b78f14fea78ec621bf4fc9e
tree88102c5ae92655b1885e7acc8c25ed10b86bc76c
parent08b25d59ffb049ca6c3ed87fecbbef70c9a16f39
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