]> git.ipfire.org Git - thirdparty/suricata-verify.git/commitdiff
tls: test for tls header inspection rules suricata-7.0.7
authorIlya Bakhtin <ilya.bakhtin@gmail.com>
Thu, 29 Aug 2024 19:18:48 +0000 (21:18 +0200)
committerVictor Julien <victor@inliniac.net>
Sat, 28 Sep 2024 05:12:41 +0000 (07:12 +0200)
Ticket - 7235

tests/tls/tls-bypass-missing-event/test.rules [new file with mode: 0644]
tests/tls/tls-bypass-missing-event/test.yaml [new file with mode: 0644]
tests/tls/tls-bypass-missing-event/tor_bl.pcap [new file with mode: 0755]

diff --git a/tests/tls/tls-bypass-missing-event/test.rules b/tests/tls/tls-bypass-missing-event/test.rules
new file mode 100644 (file)
index 0000000..98bf652
--- /dev/null
@@ -0,0 +1 @@
+alert tcp-stream any any -> any ![21,25,110,143,443,465,587,636,989:995,3128,5061,5222,8443,8080] (msg:"Policy: Possible TOR SSL traffic (TLS1.3)";flow:established,to_server; content:"|16 03 01|"; depth:3; content:"|01|"; distance:2; within:1; content:"www"; pcre:"/www.[0-9a-z]{4,25}.com/"; metadata:created_at 2022_25_07,priority:5; sid:900000004; rev:1;)
diff --git a/tests/tls/tls-bypass-missing-event/test.yaml b/tests/tls/tls-bypass-missing-event/test.yaml
new file mode 100644 (file)
index 0000000..abc28b9
--- /dev/null
@@ -0,0 +1,13 @@
+requires:
+  min-version: 7.0.7
+
+args:
+  - --set app-layer.protocols.tls.encryption-handling=bypass
+
+checks:
+
+  - filter:
+      count: 2
+      match:
+        event_type: alert
+        alert.signature_id: 900000004
diff --git a/tests/tls/tls-bypass-missing-event/tor_bl.pcap b/tests/tls/tls-bypass-missing-event/tor_bl.pcap
new file mode 100755 (executable)
index 0000000..307e452
Binary files /dev/null and b/tests/tls/tls-bypass-missing-event/tor_bl.pcap differ