Rule 942200 triggers a substantial number of false positives.
See original GitHub issueDescription
Not sure what rule 942200 is supposed to do exactly (as it’s not docummented nor has tests), but it yields a lot false-positives. For example, the simple payload like this gets blocked: ?text=yes, bob's
.
For the corpus wikipedia_2016_1M it yields 28342 results.
$ grep -i -E -c -f regexes.txt ./eng_wikipedia_2016_1M/eng_wikipedia_2016_1M-sentences.txt
28342
The the most critical expression from 942200.data is ,.*?[)\da-f\"'`][\"'`][^\"'`]+
which alone yields 27983
results.
TBF, the rule doesn’t seem to be doing anything useful (except \Wselect.+\W*?from
which doesn’t fit the rule and should be moved somewhere else) so I’d consider disabling it. One thing for sure it needs a docummentation and tests.
The usage of the word space
also seems to be a bug.
Issue Analytics
- State:
- Created a year ago
- Reactions:1
- Comments:16 (7 by maintainers)
Top Results From Across the Web
Handling False Positives with the OWASP ... - netnea
We will take a vanilla installation of the OWASP ModSecurity Core Rule Set (CRS) troubled by a large number of false positives and...
Read more >How to tune your WAF installation to reduce false positives
The first number given is the number of false positives. The second number is the ID of the rule that was triggered. The...
Read more >Troubleshoot - Azure Web Application Firewall - Microsoft Learn
Fixing false positives. With this information, and the knowledge that rule 942130 is the one that matched the 1=1 string, you can do...
Read more >[Owasp-modsecurity-core-rule-set] RegEx in CRS 3.0.2 ...
I've been looking at some false positives related to rule 942200. Side note, I'm running CRS 3.0.2 but the rules still have a...
Read more >Very large amount of false positives with rule 932200 #1818
no rule triggered at PL1 (is this sent on request body with content-type application/json?)
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Adding them to RESPONSE-999-EXCLUSION-RULES-AFTER-CRS.conf works, learning every day 😃
For people finding this ticket:
msg:'Detects MySQL comment-/space-obfuscated injections and backtick termination'
space
is a function in MysQL, apparently.The SLQi rules are a mess and we’re in the process of cleaning them up. It will probably be a while before we can address this particular issue, so I’ve added a new
sqli
label.