mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-11-19 18:54:23 +03:00
Extends the direct access model to other collections
This commit is contained in:
committed by
Felipe Zimmerle
parent
ca24b6bb06
commit
f2d149fc5f
@@ -32,7 +32,7 @@ namespace disruptive {
|
||||
bool Block::evaluate(Rule *rule, Transaction *transaction, RuleMessage *rm) {
|
||||
transaction->debug(8, "Marking request as disruptive.");
|
||||
|
||||
for (Action *a : transaction->m_rules->m_defaultActions[rule->phase]) {
|
||||
for (Action *a : transaction->m_rules->m_defaultActions[rule->m_phase]) {
|
||||
if (a->isDisruptive() == false) {
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -39,7 +39,7 @@ bool Deny::evaluate(Rule *rule, Transaction *transaction, RuleMessage *rm) {
|
||||
|
||||
log.append("Access denied with code %d");
|
||||
log.append(" (phase ");
|
||||
log.append(std::to_string(rm->m_rule->phase - 1) + "). ");
|
||||
log.append(std::to_string(rm->m_rule->m_phase - 1) + "). ");
|
||||
|
||||
transaction->m_it.disruptive = true;
|
||||
intervention::freeLog(&transaction->m_it);
|
||||
|
||||
@@ -46,7 +46,7 @@ bool Redirect::evaluate(Rule *rule, Transaction *transaction,
|
||||
}
|
||||
log.append("Access denied with code %d");
|
||||
log.append(" (phase ");
|
||||
log.append(std::to_string(rm->m_rule->phase - 1) + "). ");
|
||||
log.append(std::to_string(rm->m_rule->m_phase - 1) + "). ");
|
||||
|
||||
intervention::freeUrl(&transaction->m_it);
|
||||
transaction->m_it.url = strdup(m_urlExpanded.c_str());
|
||||
|
||||
Reference in New Issue
Block a user