]> git.ipfire.org Git - thirdparty/suricata-verify.git/commitdiff
tests/anomaly: Test case for mult. loggers
authorJeff Lucovsky <jeff@lucovsky.org>
Sat, 1 Aug 2020 13:59:27 +0000 (09:59 -0400)
committerVictor Julien <victor@inliniac.net>
Mon, 3 Aug 2020 09:00:58 +0000 (11:00 +0200)
This commit adds a test case for the issue described in bug 3835.
Multiple anomaly loggers aren't supported.

tests/output-eve-anomaly-04/input.pcap [new file with mode: 0644]
tests/output-eve-anomaly-04/suricata.yaml [new file with mode: 0644]
tests/output-eve-anomaly-04/test.yaml [new file with mode: 0644]

diff --git a/tests/output-eve-anomaly-04/input.pcap b/tests/output-eve-anomaly-04/input.pcap
new file mode 100644 (file)
index 0000000..d50be33
Binary files /dev/null and b/tests/output-eve-anomaly-04/input.pcap differ
diff --git a/tests/output-eve-anomaly-04/suricata.yaml b/tests/output-eve-anomaly-04/suricata.yaml
new file mode 100644 (file)
index 0000000..44deda8
--- /dev/null
@@ -0,0 +1,23 @@
+%YAML 1.1
+---
+
+outputs:
+  - eve-log:
+      enabled: yes
+      filename: eve.json
+      filetype: regular
+      types:
+        - anomaly:
+            types:
+                stream: yes
+                applayer: no
+
+  - eve-log:
+      enabled: yes
+      filename: eve2.json
+      filetype: regular
+      types:
+        - anomaly:
+            types:
+                stream: yes
+                applayer: no
diff --git a/tests/output-eve-anomaly-04/test.yaml b/tests/output-eve-anomaly-04/test.yaml
new file mode 100644 (file)
index 0000000..cc1cb37
--- /dev/null
@@ -0,0 +1,10 @@
+requires:
+  min-version: 6
+
+args:
+  - -k none
+
+checks:
+    - shell:
+        args: grep "only one 'anomaly' logger can be enabled" stderr | wc -l | xargs
+        expect: 1