summaryrefslogtreecommitdiffstats
path: root/tests/py/ip/ip.t.json
diff options
context:
space:
mode:
authorFlorian Westphal <fw@strlen.de>2023-10-06 10:07:01 +0200
committerPablo Neira Ayuso <pablo@netfilter.org>2023-11-03 12:24:21 +0100
commitfd74051bb75bfb5faa8f72698ea081a8addf7858 (patch)
treecc4a02e49d64fd322bce2f18989e891a4b9871df /tests/py/ip/ip.t.json
parentdc36708b9b209823f3ee8912f1d72c272bbd36da (diff)
tests: never merge across non-expression statements redux 2
commit 8b9ae77598b4d074cfa6dc263e6064d9bd5610d4 upstream. Turns out I also love to forget about nft-test.py -j. Fixes: 99ab1b8feb16 ("rule: never merge across non-expression statements") Signed-off-by: Florian Westphal <fw@strlen.de>
Diffstat (limited to 'tests/py/ip/ip.t.json')
-rw-r--r--tests/py/ip/ip.t.json61
1 files changed, 61 insertions, 0 deletions
diff --git a/tests/py/ip/ip.t.json b/tests/py/ip/ip.t.json
index b1085035..f019655e 100644
--- a/tests/py/ip/ip.t.json
+++ b/tests/py/ip/ip.t.json
@@ -1685,3 +1685,64 @@
}
]
+# ip saddr 1.2.3.4 ip daddr 3.4.5.6
+[
+ {
+ "match": {
+ "left": {
+ "payload": {
+ "field": "saddr",
+ "protocol": "ip"
+ }
+ },
+ "op": "==",
+ "right": "1.2.3.4"
+ }
+ },
+ {
+ "match": {
+ "left": {
+ "payload": {
+ "field": "daddr",
+ "protocol": "ip"
+ }
+ },
+ "op": "==",
+ "right": "3.4.5.6"
+ }
+ }
+]
+
+# ip saddr 1.2.3.4 counter ip daddr 3.4.5.6
+[
+ {
+ "match": {
+ "left": {
+ "payload": {
+ "field": "saddr",
+ "protocol": "ip"
+ }
+ },
+ "op": "==",
+ "right": "1.2.3.4"
+ }
+ },
+ {
+ "counter": {
+ "bytes": 0,
+ "packets": 0
+ }
+ },
+ {
+ "match": {
+ "left": {
+ "payload": {
+ "field": "daddr",
+ "protocol": "ip"
+ }
+ },
+ "op": "==",
+ "right": "3.4.5.6"
+ }
+ }
+]