]> git.ipfire.org Git - thirdparty/suricata-verify.git/commitdiff
http: test for body inspection corner case
authorVictor Julien <victor@inliniac.net>
Wed, 11 Dec 2019 10:05:03 +0000 (11:05 +0100)
committerVictor Julien <victor@inliniac.net>
Fri, 13 Dec 2019 10:31:39 +0000 (11:31 +0100)
tests/http-body-inspect/http-aptget-ids-02-s2.pcap [new file with mode: 0644]
tests/http-body-inspect/test.rules [new file with mode: 0644]
tests/http-body-inspect/test.yaml [new file with mode: 0644]

diff --git a/tests/http-body-inspect/http-aptget-ids-02-s2.pcap b/tests/http-body-inspect/http-aptget-ids-02-s2.pcap
new file mode 100644 (file)
index 0000000..6907fbc
Binary files /dev/null and b/tests/http-body-inspect/http-aptget-ids-02-s2.pcap differ
diff --git a/tests/http-body-inspect/test.rules b/tests/http-body-inspect/test.rules
new file mode 100644 (file)
index 0000000..93c6adc
--- /dev/null
@@ -0,0 +1 @@
+alert http any any -> any any (file_data; content:"|60 5c f3 f0 29 2b|"; sid:1;)
diff --git a/tests/http-body-inspect/test.yaml b/tests/http-body-inspect/test.yaml
new file mode 100644 (file)
index 0000000..3900881
--- /dev/null
@@ -0,0 +1,18 @@
+requires:
+  features:
+    - HAVE_LIBJANSSON
+
+args:
+- --set app-layer.protocols.http.libhtp.default-config.response-body-limit=1mb
+
+checks:
+  - filter:
+      count: 1
+      match:
+        event_type: alert
+        alert.signature_id: 1
+        tx_id: 0
+  - filter:
+      count: 1
+      match:
+        event_type: http