# CVE-2019-17221: PhantomJS Arbitrary File Read

- Severity: High 7.5 (CVSS:3.1, scored by NVD) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 3.42%, higher than 89% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2019-11-05T13:10:45.000Z
- Modified: 2026-06-17T02:23:30.113Z
- Also known as: GHSA-x43g-gj9x-838x
- Weaknesses: CWE-552
- Assigned by: mitre

## Description

PhantomJS through 2.1.1 has an arbitrary file read vulnerability, as demonstrated by an XMLHttpRequest for a file:// URI. The vulnerability exists in the page.open() function of the webpage module, which loads a specified URL and calls a given callback. An attacker can supply a specially crafted HTML file, as user input, that allows reading arbitrary files on the filesystem. For example, if page.render() is the function callback, this generates a PDF or an image of the targeted file. NOTE: this product is no longer developed.

(As written by CVE List.)

## Affected

- Unspecified product: n/a
- phantomjs (npm): up to 2.1.1
- phantomjs phantomjs: up to 2.1.1

## Every score

- GitHub: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- NVD: CVSS:3.1 7.5 High `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`
- NVD: CVSS:2.0 5.0 Medium `AV:N/AC:L/Au:N/C:P/I:N/A:N`

## References

- <https://www.darkmatter.ae/blogs/breaching-the-perimeter-phantomjs-arbitrary-file-read/> (exploit, third-party-advisory)
- <https://nvd.nist.gov/vuln/detail/CVE-2019-17221> (advisory)
- <https://github.com/Medium/phantomjs> (package)
- <https://web.archive.org/web/20191220171022/https://www.darkmatter.ae/blogs/breaching-the-perimeter-phantomjs-arbitrary-file-read> (web)

## Sources

- CVE List: [CVE-2019-17221](https://www.cve.org/CVERecord?id=CVE-2019-17221), CVE Terms of Use, modified 2024-08-05
- GitHub Advisory Database: [GHSA-x43g-gj9x-838x](https://github.com/advisories/GHSA-x43g-gj9x-838x), CC-BY-4.0, modified 2023-11-08
- NVD: [CVE-2019-17221](https://nvd.nist.gov/vuln/detail/CVE-2019-17221), Public domain, modified 2026-06-17

---

Page: https://cve.day/CVE-2019-17221 · Whole record: https://cve.day/CVE-2019-17221.json · Rebuilt by cve.day 2026-11-25T22:57:47.782Z
