]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
output-json-alert: rename applayer to metadata
authorEric Leblond <eric@regit.org>
Mon, 26 Jun 2017 08:41:11 +0000 (10:41 +0200)
committerVictor Julien <victor@inliniac.net>
Mon, 26 Jun 2017 10:31:25 +0000 (12:31 +0200)
src/output-json-alert.c
suricata.yaml.in

index 460ae7a73e4d1e2405d6783140187deb52de9d37..cd177ae965d61ba338411240772889551f6db8df 100644 (file)
@@ -88,7 +88,7 @@
 #define LOG_JSON_APP_LAYER      BIT_U16(10)
 #define LOG_JSON_FLOW           BIT_U16(11)
 
-#define LOG_JSON_APP_LAYER_ALL  (LOG_JSON_APP_LAYER|LOG_JSON_HTTP|LOG_JSON_TLS|LOG_JSON_SSH|LOG_JSON_SMTP|LOG_JSON_DNP3|LOG_JSON_FLOW)
+#define LOG_JSON_METADATA_ALL  (LOG_JSON_APP_LAYER|LOG_JSON_HTTP|LOG_JSON_TLS|LOG_JSON_SSH|LOG_JSON_SMTP|LOG_JSON_DNP3|LOG_JSON_VARS|LOG_JSON_FLOW)
 
 #define JSON_STREAM_BUFFER_SIZE 4096
 
@@ -765,7 +765,7 @@ static void XffSetup(AlertJsonOutputCtx *json_output_ctx, ConfNode *conf)
         const char *tagged_packets = ConfNodeLookupChildValue(conf, "tagged-packets");
         const char *dnp3 = ConfNodeLookupChildValue(conf, "dnp3");
         const char *vars = ConfNodeLookupChildValue(conf, "vars");
-        const char *applayer = ConfNodeLookupChildValue(conf, "applayer");
+        const char *metadata = ConfNodeLookupChildValue(conf, "metadata");
         const char *flow = ConfNodeLookupChildValue(conf, "flow");
 
         if (flow != NULL) {
@@ -778,8 +778,8 @@ static void XffSetup(AlertJsonOutputCtx *json_output_ctx, ConfNode *conf)
                 json_output_ctx->flags |= LOG_JSON_VARS;
             }
         }
-        if (applayer != NULL && ConfValIsTrue(applayer)) {
-            json_output_ctx->flags |= LOG_JSON_APP_LAYER_ALL;
+        if (metadata != NULL && ConfValIsTrue(metadata)) {
+            json_output_ctx->flags |= LOG_JSON_METADATA_ALL;
         }
         if (ssh != NULL) {
             if (ConfValIsTrue(ssh)) {
index 9cff73b7a0a170abc210a9ff97aba4b4fe5ba20f..7b2b679c893885db824e71adbf2a2c1a5abcdef7 100644 (file)
@@ -166,8 +166,7 @@ outputs:
             # payload-buffer-size: 4kb # max size of payload buffer to output in eve-log
             # payload-printable: yes   # enable dumping payload in printable (lossy) format
             # packet: yes              # enable dumping of packet (without stream segments)
-            applayer: yes            # add L7/applayer fields to the alert
-            vars: yes                # enable dumping of flowbits and other vars
+            metadata: yes              # add L7/applayer fields, flowbit and other vars to the alert
 
             # Enable the logging of tagged packets for rules using the
             # "tag" keyword.