mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-09-30 03:34:29 +03:00
General improvements on audit logs information
Making actions: msg, logdata, tag and others to work in the same fashion that they work on ModSecurity v2.x
This commit is contained in:
@@ -76,12 +76,64 @@ class Rule {
|
||||
bool m_secmarker;
|
||||
std::string m_fileName;
|
||||
int m_lineNumber;
|
||||
std::list<std::string> m_tags;
|
||||
|
||||
std::string m_log_data;
|
||||
std::string m_log_message;
|
||||
|
||||
private:
|
||||
bool m_unconditional;
|
||||
int m_referenceCount;
|
||||
};
|
||||
|
||||
class RuleMessage {
|
||||
public:
|
||||
RuleMessage(Rule *rule) {
|
||||
m_ruleFile = rule->m_fileName;
|
||||
m_ruleLine = rule->m_lineNumber;
|
||||
m_ruleId = rule->rule_id;
|
||||
m_ruleRev = 0;
|
||||
m_message = std::string("");
|
||||
m_data = std::string("");
|
||||
m_severity = std::string("");
|
||||
m_ver = std::string("");
|
||||
m_maturity = 0;
|
||||
m_accuracy = 0;
|
||||
m_tags = std::string("");
|
||||
m_rule = rule;
|
||||
};
|
||||
RuleMessage(Rule *rule, std::string message) {
|
||||
m_ruleFile = rule->m_fileName;
|
||||
m_ruleLine = rule->m_lineNumber;
|
||||
m_ruleId = rule->rule_id;
|
||||
m_ruleRev = 0;
|
||||
m_message = message;
|
||||
m_data = std::string("");
|
||||
m_severity = std::string("");
|
||||
m_ver = std::string("");
|
||||
m_maturity = 0;
|
||||
m_accuracy = 0;
|
||||
m_tags = std::string("");
|
||||
m_rule = rule;
|
||||
};
|
||||
|
||||
std::string m_match;
|
||||
std::string m_ruleFile;
|
||||
int m_ruleLine;
|
||||
int m_ruleId;
|
||||
int m_ruleRev;
|
||||
std::string m_message;
|
||||
std::string m_data;
|
||||
std::string m_severity;
|
||||
std::string m_ver;
|
||||
int m_maturity;
|
||||
int m_accuracy;
|
||||
std::string m_tags;
|
||||
|
||||
Rule *m_rule;
|
||||
};
|
||||
|
||||
|
||||
} // namespace modsecurity
|
||||
#endif
|
||||
|
||||
|
Reference in New Issue
Block a user