From: Philippe Antoine Date: Mon, 29 Jan 2024 14:24:47 +0000 (+0100) Subject: drop: adds test with a protocol change X-Git-Tag: suricata-6.0.17~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d2031f53eaaa039f2794ecb1d78887cd73b3a155;p=thirdparty%2Fsuricata-verify.git drop: adds test with a protocol change Ticket: 6305 --- diff --git a/tests/drop-protocol-change/README.md b/tests/drop-protocol-change/README.md new file mode 100644 index 000000000..ab06a10b4 --- /dev/null +++ b/tests/drop-protocol-change/README.md @@ -0,0 +1,11 @@ +# Test Description + +Test that we drop even on protocol change + +## PCAP + +Crafted from oss-fuzz reproducer + +## Related issues + +https://redmine.openinfosecfoundation.org/issues/6305 diff --git a/tests/drop-protocol-change/input.pcap b/tests/drop-protocol-change/input.pcap new file mode 100644 index 000000000..7a8a81415 Binary files /dev/null and b/tests/drop-protocol-change/input.pcap differ diff --git a/tests/drop-protocol-change/test.rules b/tests/drop-protocol-change/test.rules new file mode 100644 index 000000000..4401a9512 --- /dev/null +++ b/tests/drop-protocol-change/test.rules @@ -0,0 +1 @@ +drop http any any -> any any (msg:"drop http"; sid:1; rev:1;) diff --git a/tests/drop-protocol-change/test.yaml b/tests/drop-protocol-change/test.yaml new file mode 100644 index 000000000..5d44c49c1 --- /dev/null +++ b/tests/drop-protocol-change/test.yaml @@ -0,0 +1,19 @@ +requires: + min-version: 8 + +args: + - -k none --set stream.midstream=true + +checks: + - filter: + count: 1 + match: + event_type: flow + app_proto: http2 + app_proto_orig: http + flow.action: drop + - filter: + count: 1 + match: + event_type: alert + alert.signature_id: 1