diff --git a/tests/rules/tcp_window/test.rules b/tests/rules/tcp_window/test.rules new file mode 100644 index 000000000..646a45139 --- /dev/null +++ b/tests/rules/tcp_window/test.rules @@ -0,0 +1,2 @@ +alert tcp any any -> any any (msg:"TCP window size"; window:30336; sid:1;) +alert tcp any any -> any any (msg:"TCP window size"; tcp.window:!1024; sid:2;) \ No newline at end of file diff --git a/tests/rules/tcp_window/test.yaml b/tests/rules/tcp_window/test.yaml new file mode 100644 index 000000000..29adc7925 --- /dev/null +++ b/tests/rules/tcp_window/test.yaml @@ -0,0 +1,22 @@ +requires: + min-version: 8.0 + pcap: false + +args: + - --engine-analysis + +checks: +- filter: + filename: rules.json + count: 1 + match: + id: 1 + lists.packet.matches[0].name: "window" + lists.packet.matches[0].window.equql: 30336 +- filter: + filename: rules.json + count: 1 + match: + id: 2 + lists.packet.matches[0].name: "tcp.window" + lists.packet.matches[0].window.not.equal: 1024 \ No newline at end of file