]> git.ipfire.org Git - thirdparty/suricata-verify.git/commitdiff
snmp: add test when snmp is disabled
authorPhilippe Antoine <pantoine@oisf.net>
Fri, 18 Jul 2025 13:35:41 +0000 (15:35 +0200)
committerJason Ish <jason.ish@oisf.net>
Fri, 1 Aug 2025 16:51:28 +0000 (10:51 -0600)
Ticket: 7820

tests/snmp-disabled/README.md [new file with mode: 0644]
tests/snmp-disabled/suricata.yaml [new file with mode: 0644]
tests/snmp-disabled/test.yaml [new file with mode: 0644]

diff --git a/tests/snmp-disabled/README.md b/tests/snmp-disabled/README.md
new file mode 100644 (file)
index 0000000..73fca0f
--- /dev/null
@@ -0,0 +1,5 @@
+Test when snmp is disabled
+
+Pcap reused
+
+Ticket https://redmine.openinfosecfoundation.org/issues/7820
diff --git a/tests/snmp-disabled/suricata.yaml b/tests/snmp-disabled/suricata.yaml
new file mode 100644 (file)
index 0000000..66e695a
--- /dev/null
@@ -0,0 +1,15 @@
+%YAML 1.1
+---
+
+outputs:
+  - eve-log:
+      enabled: yes
+      filetype: regular
+      filename: eve.json
+      types:
+        - flow
+
+app-layer:
+  protocols:
+    snmp:
+      enabled: no
\ No newline at end of file
diff --git a/tests/snmp-disabled/test.yaml b/tests/snmp-disabled/test.yaml
new file mode 100644 (file)
index 0000000..348700c
--- /dev/null
@@ -0,0 +1,11 @@
+args:
+  - -k none
+
+pcap: ../snmp-v2c-get/SNMPv2c_get_requests.pcap
+
+checks:
+ - filter:
+     count: 0
+     match:
+       event_type: flow
+       app_proto: snmp