summaryrefslogtreecommitdiff
path: root/filter
diff options
context:
space:
mode:
authorOndrej Zajicek (work) <santiago@crfreenet.org>2021-05-18 19:54:18 +0200
committerOndrej Zajicek (work) <santiago@crfreenet.org>2021-05-18 19:54:18 +0200
commitdd8481cc1c92af32ec69cded42b985b7bad40b26 (patch)
tree3ff60df9e9c75dc61b3d0ca6857c3b2205ddf1db /filter
parente5468d16855600aeb8172e29936789c46ea58da0 (diff)
Flowspec: Do not use comma for bitmask operators
For numeric operators, comma is used for disjunction in expressions like "10, 20, 30..40". But for bitmask operators, comma is used for conjunction in a way that does not really make much sense. Use always explicit logical operators (&& and ||) to connect bitmask operators. Thanks to Matt Corallo for the bugreport.
Diffstat (limited to 'filter')
-rw-r--r--filter/test.conf2
1 files changed, 1 insertions, 1 deletions
diff --git a/filter/test.conf b/filter/test.conf
index 63af25bb..653bb82f 100644
--- a/filter/test.conf
+++ b/filter/test.conf
@@ -579,7 +579,7 @@ prefix p;
bt_assert(format(flow6 { sport 0..0x400; }) = "flow6 { sport 0..1024; }");
bt_assert(format(flow6 { icmp type 80; }) = "flow6 { icmp type 80; }");
bt_assert(format(flow6 { icmp code 90; }) = "flow6 { icmp code 90; }");
- bt_assert(format(flow6 { tcp flags 0x03/0x0f; }) = "flow6 { tcp flags 0x3/0x3,0x0/0xc; }");
+ bt_assert(format(flow6 { tcp flags 0x03/0x0f; }) = "flow6 { tcp flags 0x3/0x3 && 0x0/0xc; }");
bt_assert(format(flow6 { length 0..65535; }) = "flow6 { length 0..65535; }");
bt_assert(format(flow6 { dscp = 63; }) = "flow6 { dscp 63; }");
bt_assert(format(flow6 { fragment is_fragment || !first_fragment; }) = "flow6 { fragment is_fragment || !first_fragment; }");