CVE-2026-104259: ModSecurity: removeComments Transformation Fails to Strip Adjacent Comments, Enabling WAF Rule Bypass
Vulnerability summary
CVE-2026-104259 is a medium (CVSS 5.4) vulnerability in owasp-modsecurity modsecurity. EPSS estimates a 0.28% chance of exploitation in the next 30 days, higher than 21.7% of scored vulnerabilities.
Not severe (CVSS 5.4, network access); no exploitation reported by the 5 checked sources
Source freshness unavailable
How is this decided?Timeline
- 09-11-2026PublishedVulnerability first disclosed.
- 10-11-2026Last modifiedVulnerability information updated.
Description
ModSecurity is an open source, cross platform web application firewall (WAF) engine for Apache, IIS and Nginx. Prior to 2.9.15 and 3.0.17, msre_fn_removeComments_execute in apache2/re_tfns.c and inplace() in src/actions/transformations/remove_comments.cc implement t:removeComments by copying the character immediately after a comment terminator without re-evaluating it. Adjacent comments can therefore leave a later comment in the transformed value, allowing inline-comment obfuscation to bypass rules that depend on comment stripping. When a comment terminator is the final content, the same copy reads one byte beyond the input buffer. This issue is fixed in versions 2.9.15 and 3.0.17.
CVSS metrics
4 scores · 4 sources · 1 version- NVDNIST5.4MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:L/I:L/A:N
- OSV · DebianEcosystem advisory · calculated5.4MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:L/I:L/A:N
- OSV · UbuntuEcosystem advisory · calculated5.4MediumCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:L/I:L/A:N
EPSS trend
Probability
0.28%
Chance of exploitation in the next 30 days
Percentile
22%
Versus all other CVEs
30-day change
Change unavailable
Change unavailable
Known exploited
Compare KEV catalogsNot in the CISA KEV catalog.
Not in the ENISA CNW catalog.
Not in the CIRCL catalog.
Public exploits
0 foundNo public exploits indexed.
Weaknesses
CWE · root causeAffected systems
Known conditions: network-reachable, no authentication, no user interaction (CVSS vector). Other conditions: not stated in public data.
Debian2 products
- modsecurityAll versions (No fix recorded)
- modsecurity-apacheAll versions (No fix recorded)
Ubuntu2 products
- modsecurityAll versions (No fix recorded)
- modsecurity-apacheAll versions (No fix recorded)
Owasp-modsecurity1 product
- modsecurity< 2.9.15 | ≥ 3.0.0, < 3.0.17
3 vendors · 5 products
References
9 links- github.com/owasp-modsecurity/ModSecurity/security/advisories/GHSA-qrch-pjfr-9g47REPORTX Refsource CONFIRM
- github.com/owasp-modsecurity/ModSecurity/releases/tag/v2.9.15X Refsource MISC
- github.com/owasp-modsecurity/ModSecurity/releases/tag/v3.0.17X Refsource MISC