Skip to content

Inefficient Regular Expression Complexity

High
imbrn published GHSA-xrx9-gj26-5wx9 Jul 26, 2022

Package

npm v8n (npm)

Affected versions

< 1.5.1

Patched versions

1.5.1

Description

Impact

Inefficient regular expression complexity of lowercase() and uppercase() regex could lead to a denial of service attack. With a formed payload 'a' + 'a'.repeat(i) + 'A', only 32 characters payload could take 29443 ms time execution when testing lowercase(). The same issue happens with uppercase().

Patches

v1.5.1

References

huntr.dev report
Regular Expression Denial of Service (ReDoS) and Catastrophic Backtracking

For more information

If you have any questions or comments about this advisory:

Severity

High

CVE ID

CVE-2022-35923

Weaknesses

No CWEs

Credits