mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-08-14 05:45:59 +03:00
Disables @containsWord operator to enable the libpcre migration
This commit is contained in:
parent
a4cf218a3e
commit
2f4d4691c9
@ -16,7 +16,6 @@
|
||||
#include "operators/contains_word.h"
|
||||
|
||||
#include <string>
|
||||
#include <regex>
|
||||
|
||||
#include "operators/operator.h"
|
||||
|
||||
@ -42,13 +41,13 @@ bool ContainsWord::evaluate(Assay *assay,
|
||||
return 1;
|
||||
}
|
||||
|
||||
std::regex r("\\b" + this->param + "\\b");
|
||||
std::smatch m;
|
||||
if (std::regex_search(input, m, r)) {
|
||||
// std::regex r("\\b" + this->param + "\\b");
|
||||
// std::smatch m;
|
||||
// if (std::regex_search(input, m, r)) {
|
||||
// this won't find anything because 'spoons' is not
|
||||
// the word you're searching for
|
||||
return 1;
|
||||
}
|
||||
// return 1;
|
||||
// }
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user