Skip to content

Commit ec166b7

Browse files
committed
netfilter: nf_tables: disallow updates of anonymous sets
JIRA: https://issues.redhat.com/browse/RHEL-1720 JIRA: https://issues.redhat.com/browse/RHEL-1721 Upstream Status: commit b770283 commit b770283 Author: Pablo Neira Ayuso <pablo@netfilter.org> Date: Fri Jun 16 15:22:01 2023 +0200 netfilter: nf_tables: disallow updates of anonymous sets Disallow updates of set timeout and garbage collection parameters for anonymous sets. Fixes: 123b996 ("netfilter: nf_tables: honor set timeout and garbage collection updates") Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org> Signed-off-by: Florian Westphal <fwestpha@redhat.com>
1 parent 51f6ae5 commit ec166b7

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

net/netfilter/nf_tables_api.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4713,6 +4713,9 @@ static int nf_tables_newset(struct sk_buff *skb, const struct nfnl_info *info,
47134713
if (info->nlh->nlmsg_flags & NLM_F_REPLACE)
47144714
return -EOPNOTSUPP;
47154715

4716+
if (nft_set_is_anonymous(set))
4717+
return -EOPNOTSUPP;
4718+
47164719
err = nft_set_expr_alloc(&ctx, set, nla, exprs, &num_exprs, flags);
47174720
if (err < 0)
47184721
return err;

0 commit comments

Comments
 (0)