# GHSA-6chw-6frg-f759: Regular Expression Denial of Service in Acorn

- Severity: High 7.5 (CVSS:3.1, scored by GitHub) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Published: 2020-04-03T21:48:38.000Z
- Modified: 2021-08-23T15:10:32.000Z
- Weaknesses: CWE-400

## Description

Affected versions of acorn are vulnerable to Regular Expression Denial of Service.
A regex in the form of /[x-\ud800]/u causes the parser to enter an infinite loop.
The string is not valid UTF16 which usually results in it being sanitized before reaching the parser.
If an application processes untrusted input and passes it directly to acorn,
attackers may leverage the vulnerability leading to Denial of Service.

(As written by GitHub Advisory Database.)

## Affected

- acorn (npm): from 5.5.0 before 5.7.4; from 6.0.0 before 6.4.1; from 7.0.0 before 7.1.1

## References

- <https://github.com/acornjs/acorn/issues/929> (web)
- <https://github.com/acornjs/acorn/commit/793c0e569ed1158672e3a40aeed1d8518832b802> (web)
- <https://snyk.io/vuln/SNYK-JS-ACORN-559469> (web)
- <https://www.npmjs.com/advisories/1488> (web)

## Sources

- GitHub Advisory Database: [GHSA-6chw-6frg-f759](https://github.com/advisories/GHSA-6chw-6frg-f759), CC-BY-4.0, modified 2021-08-23

---

Page: https://cve.day/GHSA-6chw-6frg-f759 · Whole record: https://cve.day/GHSA-6chw-6frg-f759.json · Rebuilt by cve.day 2026-11-25T22:56:44.350Z
