LOWCVSS v3.1 3.7Vulnerability

CVE-2026-141529

### Impact `Addressable::Template` builds a regular expression from its pattern the first time it's needed, by `#match`, `#extract`, `#to_regexp`, `#variables` (and its aliases `#keys` and `#names`), `#variable_defaults` or `#freeze`. When the pattern has non-ASCII characters, or a long run of expressions with no literal text between them (such as `{a}{b}{c}`), building it takes time quadratic in the pattern's length. A non-ASCII pattern of a few hundred kilobytes takes seconds on MRI and longer on JRuby. A run of 5,000 expressions, 15 KB, takes about 4 seconds on MRI and 8 seconds on JRuby. Other templates build in linear time. The cost is in the pattern, not in the URI being matched, so only an application that builds templates from untrusted input is affected. Matching untrusted URIs against the application's own templates isn't. The regular expression is cached on the template, so the cost is paid once per template, except that `#match` and `#extract` with a processor build it on every call. `#expand` and `#partial_expand` don't build it and aren't affected. Templates from untrusted sources are uncommon, and the attacker needs a pattern of many kilobytes to cause a delay of seconds, so attack complexity is high. ### Affected Versions This vulnerability affects Addressable >= 2.9.1. Version 2.9.1 added a step that looks at what follows each expression. It finds each expression's position by character offset, and for each expression it looks through every later expression with no literal text before it, so either kind of pattern makes building the regular expression quadratic. It is fixed in 2.10.0, where the step works in byte offsets and in a single pass. ### Workarounds - Don't match, extract, list the variables of or freeze templates from untrusted sources, or limit their length. - Reject templates with non-ASCII characters, or pct-encode those characters before building the template, and reject templates with long runs of expressions next to each other

Properties

Summary
Addressable::Template builds its regexp in quadratic time for patterns with non-ASCII characters or many adjacent expressions
Severity
low
Nvd fetched at
2026-12-02T06:37:54.190518+00:00
Cvss score
3.7
Cvss severity
LOW
Retrieved at
2026-12-02T06:39:20+00:00
Ghsa published
2026-12-01T23:48:42Z
Source url
https://github.com/advisories/GHSA-h78h-gj97-g737
Ghsa updated
2026-12-01T23:48:43Z
Ghsa id
GHSA-h78h-gj97-g737
Last source
GitHub Advisory Database
Score
3.7
Cvss version
3.1
Cve id
CVE-2026-141529
Cvss vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L
First seen by Signal
2026-12-01T22:36:00+00:00
Name
CVE-2026-141529
Is ghsa only
false
Vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L
Published at
2026-12-01T21:17:12.833

Related Entities (3)

AFFECTS (1)

HAS_WEAKNESS (1)

VULNERABLE_TO (1)

Related research

Explore deeper with Ninja Signal's threat intelligence graph

CVE-2026-141529 (CVSS v3.1 3.7) — Ninja Signal Threat Intelligence | Ninja Signal