mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-09-30 03:34:29 +03:00
Refactoring on {global,ip,resources,session,tx,user} collections
Now using the same name schema and interface for these "special" collection. Fix: #1754, #1778
This commit is contained in:
@@ -105,9 +105,10 @@ void InMemoryPerProcess::resolveMultiMatches(const std::string& var,
|
||||
l->insert(l->begin(), new VariableValue(&m_name, &i.first, &i.second));
|
||||
}
|
||||
} else {
|
||||
auto range = this->equal_range(var);
|
||||
for (auto it = range.first; it != range.second; ++it) {
|
||||
l->insert(l->begin(), new VariableValue(&m_name, &var, &it->second));
|
||||
for (auto &a : *this) {
|
||||
if (a.first.compare(0, var.size(), var) == 0) {
|
||||
l->insert(l->begin(), new VariableValue(&m_name, &var, &a.second));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -116,7 +117,6 @@ void InMemoryPerProcess::resolveMultiMatches(const std::string& var,
|
||||
void InMemoryPerProcess::resolveRegularExpression(const std::string& var,
|
||||
std::vector<const VariableValue *> *l) {
|
||||
|
||||
|
||||
//if (var.find(":") == std::string::npos) {
|
||||
// return;
|
||||
//}
|
||||
|
Reference in New Issue
Block a user