CVE Database›Document archive›CVE-2026-4926

CVE-2026-4926

path-to-regexp: path-to-regexp: Denial of Service via crafted regular expressions

Loading…

Severity

Important

Red Hat Product Security

7.5

CVSS 3.1

Review impact separately from score.

Published · March 27, 2026

Updated · November 5, 2026

Description

A flaw was found in path-to-regexp. A remote attacker could exploit this vulnerability by providing specially crafted input that generates a regular expression with multiple sequential optional groups. This leads to an exponential growth in the generated regular expression, causing a Denial of Service (DoS) due to excessive resource consumption.

Statement

This is an Important flaw in path-to-regexp that can lead to a Denial of Service. The vulnerability occurs when specially crafted input containing multiple sequential optional groups is used to generate regular expressions, causing exponential resource consumption.

The Red Hat Advanced Cluster Security is not affected by this issue since it's shipping a path-to-regexp version which doesn't contain the vulnerable code.

CVSS score applicability

The CVSS score(s) listed for this vulnerability do not reflect the associated product's status, and are included for informational purposes to better understand the severity of this vulnerability.

Mitigation

To mitigate this vulnerability, limit the use of multiple sequential optional groups in route patterns within applications that use path-to-regexp. Additionally, avoid directly passing user-controlled input as route patterns to prevent the generation of maliciously crafted regular expressions.

CVSS / CWE

CVSS 3.1 · 7.5
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

CWE-1333 · Inefficient Regular Expression Complexity