HighGHSA-grv7-fg5c-xmjgCVE-2024-4068

Uncontrolled resource consumption in braces

Published 14 May 2024 · Updated 10 Sept 2026

Affected package

Affected
<3.0.3
Fixed in
3.0.3
Update to the fixed version for your release line, for example:npm install braces@3.0.3

Details

The NPM package braces fails to limit the number of characters it can handle, which could lead to Memory Exhaustion. In lib/parse.js, if a malicious user sends "imbalanced braces" as input, the parsing will enter a loop, which will cause the program to start allocating heap memory without freeing it at any moment of the loop. Eventually, the JavaScript heap limit is reached, and the program will crash.

Is GHSA-grv7-fg5c-xmjg in any of your client repos?

Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected braces, and gives you the command that fixes it.

References

Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.