Adds support the variable rule

Issue #1016
This commit is contained in:
Felipe Zimmerle
2016-06-20 13:52:45 -03:00
parent 45bfb594b9
commit 56d084a7f4
12 changed files with 415 additions and 6 deletions

View File

@@ -53,11 +53,16 @@ bool Msg::evaluate(Rule *rule, Transaction *transaction) {
transaction->debug(9, "Saving msg: " + msg);
#endif
rule->m_log_message = msg;
rule->m_log_message = data(transaction);
return true;
}
std::string Msg::data(Transaction *transaction) {
return MacroExpansion::expand(m_parser_payload, transaction);
}
} // namespace actions
} // namespace modsecurity