Red Hat VEX
RHVEX-CVE-2024-4068
braces: fails to limit the number of characters it can handle
Details
A flaw was found in the NPM package braces. It 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, causing 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.
Affected packages
| Ecosystem | Package | Affected versions |
|---|---|---|
| Red Hat:enterprise_linux:10 | nodejs-nodemon | All versions, no fix yet |
| Red Hat:enterprise_linux:6 | firefox | All versions, no fix (out of support scope) |
| Red Hat:enterprise_linux:6 | thunderbird | All versions, no fix (out of support scope) |
| Red Hat:enterprise_linux:7 | firefox | All versions, no fix (out of support scope) |
| Red Hat:enterprise_linux:7 | thunderbird | All versions, no fix (out of support scope) |
| Red Hat:enterprise_linux:8 | nodejs-nodemon | All versions, will not be fixed |
| Red Hat:enterprise_linux:8 | pcs | All versions, will not be fixed |
| Red Hat:enterprise_linux:8 | pcs-snmp | All versions, will not be fixed |
| Red Hat:enterprise_linux:9 | nodejs-nodemon | All versions, will not be fixed |
| Red Hat:enterprise_linux:9 | pcs | All versions, will not be fixed |
| Red Hat:enterprise_linux:9 | pcs-snmp | All versions, will not be fixed |
References
- https://access.redhat.com/security/cve/CVE-2024-4068
- https://bugzilla.redhat.com/show_bug.cgi?id=2280600
- https://www.cve.org/CVERecord?id=CVE-2024-4068
- https://nvd.nist.gov/vuln/detail/CVE-2024-4068
- https://devhub.checkmarx.com/cve-details/CVE-2024-4068/
- https://github.com/micromatch/braces/blob/98414f9f1fabe021736e26836d8306d5de747e0d/lib/parse.js#L308
- https://github.com/micromatch/braces/issues/35