diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2021-10-25 23:46:36 +0200 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2021-10-27 00:37:46 +0200 |
commit | a99486e8cd237a84acd3613f79f82d74f192ceaa (patch) | |
tree | 3664c29064c85f3c1355d44e1819c3e9323d05ec | |
parent | 8ad4003f8b790ffefb44005254451d91ac4221b6 (diff) |
cache: honor table in set filtering
Check if table mismatch, in case the same set name is used in different
tables.
Fixes: 635ee1cad8aa ("cache: filter out sets and maps that are not requested")
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
-rw-r--r-- | src/cache.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cache.c b/src/cache.c index 691e8131..f62c9b96 100644 --- a/src/cache.c +++ b/src/cache.c @@ -377,7 +377,8 @@ static int set_cache_cb(struct nftnl_set *nls, void *arg) return -1; if (ctx->filter && ctx->filter->set && - (strcmp(ctx->filter->set, set->handle.set.name))) { + (strcmp(ctx->filter->table, set->handle.table.name) || + strcmp(ctx->filter->set, set->handle.set.name))) { set_free(set); return 0; } |