diff options
author | Thomas Haller <thaller@redhat.com> | 2023-11-21 14:22:54 +0100 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2023-11-22 12:15:54 +0100 |
commit | 485efcd3df69999d713031433d862147eba15cde (patch) | |
tree | bec7f837b12e5e508871d3e34f2474b6757ffb60 /tests/shell/testcases/optimizations/dumps/merge_vmaps.json-nft | |
parent | cb2c37ca3adb7809035ec4ff5d01ffa532839875 (diff) |
tests/shell: sanitize "handle" in JSON output
The "handle" in JSON output is not stable. Sanitize/normalize to zero.
Adjust the sanitize code, and regenerate the .json-nft files.
Signed-off-by: Thomas Haller <thaller@redhat.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'tests/shell/testcases/optimizations/dumps/merge_vmaps.json-nft')
-rw-r--r-- | tests/shell/testcases/optimizations/dumps/merge_vmaps.json-nft | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/shell/testcases/optimizations/dumps/merge_vmaps.json-nft b/tests/shell/testcases/optimizations/dumps/merge_vmaps.json-nft index 9f65daec..3711e31e 100644 --- a/tests/shell/testcases/optimizations/dumps/merge_vmaps.json-nft +++ b/tests/shell/testcases/optimizations/dumps/merge_vmaps.json-nft @@ -1 +1 @@ -{"nftables": [{"metainfo": {"version": "VERSION", "release_name": "RELEASE_NAME", "json_schema_version": 1}}, {"table": {"family": "ip", "name": "x", "handle": 2}}, {"set": {"family": "ip", "name": "s", "table": "x", "type": "ipv4_addr", "handle": 4, "size": 65535, "flags": ["dynamic"]}}, {"chain": {"family": "ip", "table": "x", "name": "filter_in_tcp", "handle": 1}}, {"chain": {"family": "ip", "table": "x", "name": "filter_in_udp", "handle": 2}}, {"chain": {"family": "ip", "table": "x", "name": "y", "handle": 3}}, {"rule": {"family": "ip", "table": "x", "chain": "y", "handle": 5, "expr": [{"set": {"op": "update", "elem": {"payload": {"protocol": "ip", "field": "saddr"}}, "set": "@s", "stmt": [{"limit": {"rate": 12, "burst": 30, "per": "minute"}}]}}, {"accept": null}]}}, {"rule": {"family": "ip", "table": "x", "chain": "y", "handle": 7, "expr": [{"vmap": {"key": {"payload": {"protocol": "tcp", "field": "dport"}}, "data": {"set": [[80, {"accept": null}], [81, {"accept": null}], [443, {"accept": null}], [{"range": [8000, 8100]}, {"accept": null}], [{"range": [24000, 25000]}, {"accept": null}]]}}}]}}, {"rule": {"family": "ip", "table": "x", "chain": "y", "handle": 9, "expr": [{"vmap": {"key": {"meta": {"key": "l4proto"}}, "data": {"set": [["tcp", {"goto": {"target": "filter_in_tcp"}}], ["udp", {"goto": {"target": "filter_in_udp"}}]]}}}]}}, {"rule": {"family": "ip", "table": "x", "chain": "y", "handle": 10, "expr": [{"log": null}]}}]} +{"nftables": [{"metainfo": {"version": "VERSION", "release_name": "RELEASE_NAME", "json_schema_version": 1}}, {"table": {"family": "ip", "name": "x", "handle": 0}}, {"set": {"family": "ip", "name": "s", "table": "x", "type": "ipv4_addr", "handle": 0, "size": 65535, "flags": ["dynamic"]}}, {"chain": {"family": "ip", "table": "x", "name": "filter_in_tcp", "handle": 0}}, {"chain": {"family": "ip", "table": "x", "name": "filter_in_udp", "handle": 0}}, {"chain": {"family": "ip", "table": "x", "name": "y", "handle": 0}}, {"rule": {"family": "ip", "table": "x", "chain": "y", "handle": 0, "expr": [{"set": {"op": "update", "elem": {"payload": {"protocol": "ip", "field": "saddr"}}, "set": "@s", "stmt": [{"limit": {"rate": 12, "burst": 30, "per": "minute"}}]}}, {"accept": null}]}}, {"rule": {"family": "ip", "table": "x", "chain": "y", "handle": 0, "expr": [{"vmap": {"key": {"payload": {"protocol": "tcp", "field": "dport"}}, "data": {"set": [[80, {"accept": null}], [81, {"accept": null}], [443, {"accept": null}], [{"range": [8000, 8100]}, {"accept": null}], [{"range": [24000, 25000]}, {"accept": null}]]}}}]}}, {"rule": {"family": "ip", "table": "x", "chain": "y", "handle": 0, "expr": [{"vmap": {"key": {"meta": {"key": "l4proto"}}, "data": {"set": [["tcp", {"goto": {"target": "filter_in_tcp"}}], ["udp", {"goto": {"target": "filter_in_udp"}}]]}}}]}}, {"rule": {"family": "ip", "table": "x", "chain": "y", "handle": 0, "expr": [{"log": null}]}}]} |