RubyGems
CVE-2026-126350
Addressable: Regular Expression Denial of Service in templates with certain exploded expressions
- Severity
- Medium 5.9
- Published
- 12 Nov 2026
- Last changed
- 12 Nov 2026
- Added to UpHeron
- 23 Nov 2026
- Fixed in
- 2.9.1
- Exploit chance
- 0.4% in the next 30 daysHigher than 36% of CVEs. EPSS by FIRST, 24 Nov 2026
- Attack
- Over the network · Only under certain conditions · No login needed · No user action needed
- Attacker can
- Take it down
- CVSS vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H- Also known as
- GHSA-j82w-28jv-3pmj
- Sources
- OSV.dev and GitHub
Description
Within the URI template implementation in Addressable, templates using the (explode) modifier with the /, ., ;, ? or & operators (e.g., {/segments}, {.ext*}, {;params*}, {?query*}) generate regular expressions vulnerable to catastrophic backtracking. When Template#match or Template#extract` is called with a maliciously crafted URI that starts with the operator's leading character, matching takes exponential time, leading to uncontrolled resource consumption and denial of service. An input under 60 bytes is enough to occupy a thread for minutes.
GHSA-h27x-rffw-24p4 (CVE-2026-35611) reported this pattern as fully remediated in 2.9.0. The 2.9.0 fix only made the joiner between exploded members mandatory for templates without an operator, and its regression specs used inputs that never start with the operator's leading character, so the vulnerable part of the expression was never reached. This issue was originally reported in #364 by @ebenoist in 2019 but insufficiently investigated.
Workarounds
- Upgrade to MRI Ruby 3.2 or later, if the consuming application does not use JRuby.
- Avoid matching user-supplied input on unpatched versions of the library against templates that use the * modifier with the /, ., ;, ? or & operators.
- Apply a short timeout around any call to Template#match or Template#extract that processes user-supplied data.
Affected software
| Software | Affected versions |
|---|---|
addressableRubyGems · osv:RubyGems:addressable |
|
About addressable
- Total downloads (RubyGems)
- 1,317,979,305RubyGems, 24 Nov 2026
Vulnerabilities in addressable
- In our list
- 6
- Published in the last 12 months
- 6
- Critical, last 12 months
- 0
- High, last 12 months
- 0
- Known exploited
- 0
- CVE-2026-126348Addressable display_uri can show misleading hosts with invalid Punycode A-labelsMedium 4.3 12 Nov 2026
- CVE-2026-126349Addressable display_uri can show misleading hosts containing bidi and invisible charactersLow 3.1 12 Nov 2026
- CVE-2026-126351Addressable: Denial of service in URI path normalizationMedium 5.9 12 Nov 2026
- CVE-2026-126352Addressable: Regular Expression Denial of Service in templates with multiple variablesMedium 5.9 12 Nov 2026
- CVE-2026-126354Addressable URI normalization resolves some dotted path segments to the wrong pathMedium 4.8 12 Nov 2026
References
- CVE.org https://www.cve.org/CVERecord?id=CVE-2026-126350
- GitHub Advisory Database https://github.com/advisories/GHSA-j82w-28jv-3pmj