Skip to content

Commit b770283

Browse files
committed
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 <[email protected]>
1 parent 62e1e94 commit b770283

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
@@ -4963,6 +4963,9 @@ static int nf_tables_newset(struct sk_buff *skb, const struct nfnl_info *info,
49634963
if (info->nlh->nlmsg_flags & NLM_F_REPLACE)
49644964
return -EOPNOTSUPP;
49654965

4966+
if (nft_set_is_anonymous(set))
4967+
return -EOPNOTSUPP;
4968+
49664969
err = nft_set_expr_alloc(&ctx, set, nla, exprs, &num_exprs, flags);
49674970
if (err < 0)
49684971
return err;

0 commit comments

Comments
 (0)