mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-11-17 01:51:52 +03:00
Adds support for RunTimeString
Using RunTimeStrings instead of runtime parser for macro expansion.
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
|
||||
#include "modsecurity/actions/action.h"
|
||||
#include "modsecurity/rule_message.h"
|
||||
#include "src/run_time_string.h"
|
||||
|
||||
#ifndef SRC_ACTIONS_MSG_H_
|
||||
#define SRC_ACTIONS_MSG_H_
|
||||
@@ -34,10 +35,15 @@ class Msg : public Action {
|
||||
explicit Msg(std::string action)
|
||||
: Action(action, RunTimeOnlyIfMatchKind) { }
|
||||
|
||||
explicit Msg(std::unique_ptr<RunTimeString> z)
|
||||
: Action("msg", RunTimeOnlyIfMatchKind),
|
||||
m_string(std::move(z)) { }
|
||||
|
||||
bool evaluate(Rule *rule, Transaction *transaction,
|
||||
std::shared_ptr<RuleMessage> rm) override;
|
||||
|
||||
std::string data(Transaction *Transaction);
|
||||
std::unique_ptr<RunTimeString> m_string;
|
||||
};
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user