DoS via Exponential Regex Expansion in path-to-regexp 8.4.0
CVE-2026-4926 Published on March 26, 2026
path-to-regexp vulnerable to Denial of Service via sequential optional groups
Impact:
A bad regular expression is generated any time you have multiple sequential optional groups (curly brace syntax), such as `{a}{b}{c}:z`. The generated regex grows exponentially with the number of groups, causing denial of service.
Patches:
Fixed in version 8.4.0.
Workarounds:
Limit the number of sequential optional groups in route patterns. Avoid passing user-controlled input as route patterns.
Vulnerability Analysis
CVE-2026-4926 is exploitable with network access, and does not require authorization privileges or user interaction. This vulnerability is considered to have a low attack complexity. The potential impact of an exploit of this vulnerability is considered to have no impact on confidentiality and integrity, and a high impact on availability.
Weakness Types
What is a Resource Exhaustion Vulnerability?
The software does not properly control the allocation and maintenance of a limited resource, thereby enabling an actor to influence the amount of resources consumed, eventually leading to the exhaustion of available resources.
CVE-2026-4926 has been classified to as a Resource Exhaustion vulnerability or weakness.
What is a ReDoS Vulnerability?
The product uses a regular expression with an inefficient, possibly exponential worst-case computational complexity that consumes excessive CPU cycles. Some regular expression engines have a feature called "backtracking". If the token cannot match, the engine "backtracks" to a position that may result in a different token that can match. Backtracking becomes a weakness if all of these conditions are met:
CVE-2026-4926 has been classified to as a ReDoS vulnerability or weakness.
Products Associated with CVE-2026-4926
Want to know whenever a new CVE is published for Red Hat products? stack.watch will email you.
Affected Versions
path-to-regexp:- Version 8.0.0 and below 8.4.0 is affected.
- Version 8.4.0 is unaffected.
Exploit Probability
EPSS (Exploit Prediction Scoring System) scores estimate the probability that a vulnerability will be exploited in the wild within the next 30 days. The percentile shows you how this score compares to all other vulnerabilities.