mirror of
https://github.com/owasp-modsecurity/ModSecurity.git
synced 2025-08-14 05:45:59 +03:00
Replaces lower case implementation
This commit is contained in:
parent
1d33015934
commit
69d1112da3
6
CHANGES
6
CHANGES
@ -1,6 +1,8 @@
|
|||||||
v3.x.y - YYYY-MMM-DD (to be released)
|
v3.x.y - YYYY-MMM-DD (to be released)
|
||||||
-------------------------------------
|
-------------------------------------
|
||||||
|
|
||||||
|
- Replaced t:lowerCase backend for a better performance.
|
||||||
|
[@zimmerle]
|
||||||
- More structured rules dump. Better supporting debugging.
|
- More structured rules dump. Better supporting debugging.
|
||||||
[@zimmerle]
|
[@zimmerle]
|
||||||
- Added the basics for supporting better error/warning handling while
|
- Added the basics for supporting better error/warning handling while
|
||||||
|
@ -30,11 +30,8 @@ namespace transformations {
|
|||||||
void LowerCase::execute(Transaction *t,
|
void LowerCase::execute(Transaction *t,
|
||||||
ModSecString &in,
|
ModSecString &in,
|
||||||
ModSecString &out) {
|
ModSecString &out) {
|
||||||
std::locale loc;
|
|
||||||
out.resize(in.size());
|
out.resize(in.size());
|
||||||
for (std::string::size_type i=0; i < in.size(); ++i) {
|
std::transform(in.begin(), in.end(), out.begin(), ::tolower);
|
||||||
out[i] = std::tolower(in[i], loc);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user