mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-11-18 02:10:36 +03:00
Using run time string on the operators
This commit is contained in:
@@ -27,8 +27,7 @@ namespace operators {
|
||||
bool Eq::evaluate(Transaction *transaction, const std::string &input) {
|
||||
int p = 0;
|
||||
int i = 0;
|
||||
bool eq = false;
|
||||
std::string pt = MacroExpansion::expand(m_param, transaction);
|
||||
std::string pt(m_string->evaluate(transaction));
|
||||
|
||||
try {
|
||||
p = std::stoi(pt);
|
||||
@@ -41,9 +40,7 @@ bool Eq::evaluate(Transaction *transaction, const std::string &input) {
|
||||
i = 0;
|
||||
}
|
||||
|
||||
eq = p == i;
|
||||
|
||||
return eq;
|
||||
return p == i;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user