Skip to content

Commit 9ee4127

Browse files
author
Felipe Zimmerle
committed
parser: Improves the reading for the url in the redirect action
1 parent 8c66a1b commit 9ee4127

File tree

4 files changed

+3103
-3082
lines changed

4 files changed

+3103
-3082
lines changed

src/actions/disruptive/redirect.cc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222

2323
#include "modsecurity/transaction.h"
2424
#include "src/macro_expansion.h"
25+
#include "src/utils/string.h"
2526

2627
namespace modsecurity {
2728
namespace actions {
@@ -30,6 +31,7 @@ namespace disruptive {
3031

3132
bool Redirect::init(std::string *error) {
3233
m_url = m_parser_payload;
34+
m_url = utils::string::parserSanitizer(m_url);
3335
m_status = 302;
3436
return true;
3537
}

0 commit comments

Comments
 (0)