]> git.ipfire.org Git - thirdparty/snort3.git/commitdiff
Pull request #3242: detection: change output format of dump-rule-state
authorMike Stepanek (mstepane) <mstepane@cisco.com>
Wed, 26 Jan 2022 13:38:03 +0000 (13:38 +0000)
committerMike Stepanek (mstepane) <mstepane@cisco.com>
Wed, 26 Jan 2022 13:38:03 +0000 (13:38 +0000)
Merge in SNORT/snort3 from ~VHORBATO/snort3:drs_change to master

Squashed commit of the following:

commit 2ec901b110ad16237d1e5c9f330cf8c7f8a6f23a
Author: Vitalii <vhorbato@cisco.com>
Date:   Tue Jan 18 17:16:31 2022 +0200

    detection: change output format of dump-rule-state

src/detection/signature.cc

index eb8e396564de010c92cceb8ab155c8342d08926e..2ba2f3d33ad45463e7bec370c153ee1dd06c8bb1 100644 (file)
@@ -480,8 +480,8 @@ void dump_rule_state(const SnortConfig* sc)
             std::string action = Actions::get_string(rtn->action);
             json.put("action", action.c_str());
 
-            const char* s = rtn->enabled() ? "enabled" : "disabled";
-            json.put("state", s);
+            const char* s = rtn->enabled() ? "yes" : "no";
+            json.put("enable", s);
 
             json.close();
         }