--- /dev/null
+%YAML 1.1
+---
+
+include: ../../etc/suricata-4.0.3.yaml
+
+# Configure the type of alert (and other) logging you would like.
+outputs:
+ - eve-log:
+ enabled: yes
+ filetype: regular
+ filename: eve.json
+
+ # Enable to disable top-level metadata logging. Default: yes.
+ #metadata: no
+
+ types:
+ - alert
+ - http:
+ extended: yes
+ - dns:
+ query: yes # enable logging of DNS queries
+ answer: yes # enable logging of DNS answers
+ - tls:
+ extended: yes # enable this for extended logging information
+ - files:
+ force-magic: no # force logging magic on all logged files
+ - smtp:
+ - ssh
+ - stats:
+ totals: yes # stats for all threads merged together
+ threads: no # per thread stats
+ deltas: no # include delta values
+ - flow
+ - netflow
+ - metadata
--- /dev/null
+# Silly rule to set the flowbit "traffic/label/cli-http" on
+# the curl user-agent.
+alert http any any -> any any (msg:"TEST"; \
+ content:"curl"; \
+ http_user_agent; \
+ metadata:tag tag1, created_at 2018-01-30; \
+ sid:1; rev:1;)
--- /dev/null
+requires:
+
+ script:
+ - grep METADATA_DEFAULTS src/output-json-alert.c > /dev/null
+
+checks:
+
+ - filter:
+ count: 1
+ match:
+ event_type: alert
+ alert.metadata.created_at[0]: "2018-01-30"
+ alert.metadata.tag[0]: "tag1"
+ has-key: flow
+ has-key: http
+ not-has-key: alert.rule
--- /dev/null
+%YAML 1.1
+---
+
+include: ../../etc/suricata-4.0.3.yaml
+
+# Configure the type of alert (and other) logging you would like.
+outputs:
+ - eve-log:
+ enabled: yes
+ filetype: regular
+ filename: eve.json
+
+ # Enable to disable top-level metadata logging. Default: yes.
+ #metadata: no
+
+ types:
+ - alert:
+ metadata:
+ rule:
+ raw: true
+ - http:
+ extended: yes
+ - dns:
+ query: yes # enable logging of DNS queries
+ answer: yes # enable logging of DNS answers
+ - tls:
+ extended: yes # enable this for extended logging information
+ - files:
+ force-magic: no # force logging magic on all logged files
+ - smtp:
+ - ssh
+ - stats:
+ totals: yes # stats for all threads merged together
+ threads: no # per thread stats
+ deltas: no # include delta values
+ - flow
+ - netflow
+ - metadata
--- /dev/null
+# Silly rule to set the flowbit "traffic/label/cli-http" on
+# the curl user-agent.
+alert http any any -> any any (msg:"TEST"; \
+ content:"curl"; \
+ http_user_agent; \
+ metadata:tag tag1, created_at 2018-01-30; \
+ sid:1; rev:1;)
--- /dev/null
+requires:
+
+ script:
+ - grep METADATA_DEFAULTS src/output-json-alert.c > /dev/null
+
+checks:
+
+ - filter:
+ count: 1
+ match:
+ event_type: alert
+ alert.metadata.created_at[0]: "2018-01-30"
+ alert.metadata.tag[0]: "tag1"
+ has-key: flow
+ has-key: http
+ has-key: alert.rule
--- /dev/null
+%YAML 1.1
+---
+
+include: ../../etc/suricata-4.0.3.yaml
+
+# Configure the type of alert (and other) logging you would like.
+outputs:
+ - eve-log:
+ enabled: yes
+ filetype: regular
+ filename: eve.json
+
+ # Enable to disable top-level metadata logging. Default: yes.
+ #metadata: no
+
+ types:
+ - alert:
+ metadata: false
+ - http:
+ extended: yes
+ - dns:
+ query: yes # enable logging of DNS queries
+ answer: yes # enable logging of DNS answers
+ - tls:
+ extended: yes # enable this for extended logging information
+ - files:
+ force-magic: no # force logging magic on all logged files
+ - smtp:
+ - ssh
+ - stats:
+ totals: yes # stats for all threads merged together
+ threads: no # per thread stats
+ deltas: no # include delta values
+ - flow
+ - netflow
+ - metadata
--- /dev/null
+# Silly rule to set the flowbit "traffic/label/cli-http" on
+# the curl user-agent.
+alert http any any -> any any (msg:"TEST"; \
+ content:"curl"; \
+ http_user_agent; \
+ metadata:tag tag1, created_at 2018-01-30; \
+ sid:1; rev:1;)
--- /dev/null
+requires:
+
+ script:
+ - grep METADATA_DEFAULTS src/output-json-alert.c > /dev/null
+
+checks:
+
+ - filter:
+ count: 1
+ match:
+ event_type: alert
+ not-has-key: flow
+ not-has-key: http
+ not-has-key: alert.metadata
+ not-has-key: alert.rule