From: Philippe Antoine Date: Wed, 30 Sep 2020 12:35:33 +0000 (+0200) Subject: Adds test with HTTP connect followed by parser failure X-Git-Tag: suricata-6.0.4~226 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7045dfaaefbd85edb4a2566293cd61c80160c384;p=thirdparty%2Fsuricata-verify.git Adds test with HTTP connect followed by parser failure --- diff --git a/tests/http-connect/http-connect-fail/README.md b/tests/http-connect/http-connect-fail/README.md new file mode 100644 index 000000000..979898975 --- /dev/null +++ b/tests/http-connect/http-connect-fail/README.md @@ -0,0 +1,7 @@ +# Description + +Test HTTP CONNECT followed by TLS with decode failure + +# PCAP + +The pcap comes from running txt2pcap.py with input.txt diff --git a/tests/http-connect/http-connect-fail/input.pcap b/tests/http-connect/http-connect-fail/input.pcap new file mode 100644 index 000000000..d4380609d Binary files /dev/null and b/tests/http-connect/http-connect-fail/input.pcap differ diff --git a/tests/http-connect/http-connect-fail/input.txt b/tests/http-connect/http-connect-fail/input.txt new file mode 100644 index 000000000..3f5807724 --- /dev/null +++ b/tests/http-connect/http-connect-fail/input.txt @@ -0,0 +1,3 @@ +c2s CONNECT abc:443 HTTP/1.1\r\nUser-Agent: Victor/1.0\r\n\r\n +s2c HTTP/1.1 200 OK\r\nServer: VictorServer/1.0\r\n\r\n +s2c \x05\x00\x00\x05\x00 diff --git a/tests/http-connect/http-connect-fail/test.yaml b/tests/http-connect/http-connect-fail/test.yaml new file mode 100644 index 000000000..6ece99ebd --- /dev/null +++ b/tests/http-connect/http-connect-fail/test.yaml @@ -0,0 +1,29 @@ +requires: + features: + - HAVE_LIBJANSSON + +# disables checksum verification +args: + - -k none + +checks: + + # Check that there is one file event with content range. + - filter: + count: 1 + match: + event_type: http + tx_id: 0 + http.http_method: CONNECT + http.protocol: HTTP/1.1 + http.status: 200 + - filter: + count: 1 + match: + event_type: flow + app_proto: dcerpc + app_proto_orig: http + - filter: + count: 0 + match: + event_type: dcerpc