Skip to content

Commit

Permalink
netfilter: nf_tables: do not compare internal table flags on updates
Browse files Browse the repository at this point in the history
[ Upstream commit 4a0e7f2decbf9bd72461226f1f5f7dcc4b08f139 ]

Restore skipping transaction if table update does not modify flags.

Fixes: 179d9ba ("netfilter: nf_tables: fix table flag updates")
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
ummakynes authored and Sasha Levin committed Mar 26, 2024
1 parent 9384b4d commit df257c4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/netfilter/nf_tables_api.c
Expand Up @@ -1211,7 +1211,7 @@ static int nf_tables_updtable(struct nft_ctx *ctx)
if (flags & ~NFT_TABLE_F_MASK)
return -EOPNOTSUPP;

if (flags == ctx->table->flags)
if (flags == (ctx->table->flags & NFT_TABLE_F_MASK))
return 0;

if ((nft_table_has_owner(ctx->table) &&
Expand Down

0 comments on commit df257c4

Please sign in to comment.