mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-11-17 09:55:28 +03:00
actions: Removes Rule parameter from runtime execute
Generals organization on the Action class
This commit is contained in:
committed by
Felipe Zimmerle
parent
eb3e05646d
commit
bf3a1d84ff
@@ -13,42 +13,39 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include <string>
|
||||
#include <memory>
|
||||
#include <utility>
|
||||
|
||||
#include "modsecurity/actions/action.h"
|
||||
|
||||
#include "src/actions/action_with_run_time_string.h"
|
||||
#include "src/run_time_string.h"
|
||||
|
||||
|
||||
#ifndef SRC_ACTIONS_LOG_DATA_H_
|
||||
#define SRC_ACTIONS_LOG_DATA_H_
|
||||
|
||||
class Transaction;
|
||||
|
||||
namespace modsecurity {
|
||||
class Transaction;
|
||||
namespace actions {
|
||||
|
||||
|
||||
class LogData : public ActionWithRunTimeString {
|
||||
public:
|
||||
explicit LogData(std::unique_ptr<RunTimeString> runTimeString)
|
||||
: ActionWithRunTimeString(
|
||||
"logdata",
|
||||
RunTimeOnlyIfMatchKind,
|
||||
std::move(runTimeString)
|
||||
)
|
||||
{ };
|
||||
: ActionWithRunTimeString(std::move(runTimeString)),
|
||||
Action("logdata")
|
||||
{ }
|
||||
|
||||
explicit LogData(const LogData &data)
|
||||
: ActionWithRunTimeString(data)
|
||||
{ };
|
||||
: ActionWithRunTimeString(data),
|
||||
Action(data)
|
||||
{ }
|
||||
|
||||
bool execute(RuleWithActions *rule, Transaction *transaction) override;
|
||||
bool execute(Transaction *transaction) noexcept override;
|
||||
|
||||
virtual ActionWithRunTimeString *clone() override {
|
||||
ActionWithRunTimeString *clone() override {
|
||||
return new LogData(*this);
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user