GitHub Advisoryadvisory · npm
GHSA-7jg2-jgv3-fmr4 Malicious PDF can inject JavaScript into PDF Viewer
HIGH
Official page ↗
- Aliases
- CVE-2018-5158
- Ecosystem
- npm
- Packages
- pdfjs-dist
- Severity
- High
- CVSS vector
- CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
- Weaknesses
- CWE-94
- Reviewed
- 2024-05-28
Affected packages
• npm pdfjs-dist: >= 2.0.0, < 2.0.550 → fixed in 2.0.550
• npm pdfjs-dist: < 1.10.100 → fixed in 1.10.100
Description
The PDF viewer does not sufficiently sanitize PostScript calculator functions, allowing malicious JavaScript to be injected through a crafted PDF file. This JavaScript can then be run with the permissions of the PDF viewer by its worker. This vulnerability affects Firefox ESR < 52.8, Firefox < 60 and PDF.js < 2.0.550.
Related
Alias · CVE (1)
- CVE-2018-5158 The PDF viewer does not sufficiently sanitize PostScript calculator functions, allowing malicious JavaScript to be injected through a… vulnerability
Weakness · CWE (1)
- CWE-94 Improper Control of Generation of Code weakness
References
- https://nvd.nist.gov/vuln/detail/CVE-2018-5158 advisory
- https://github.com/mozilla/pdf.js/pull/9659 web
- https://github.com/mozilla/pdf.js/commit/2dc4af525d1612c98afcd1e6bee57d4788f78f97 web
- https://access.redhat.com/errata/RHSA-2018:1414 web
- https://access.redhat.com/errata/RHSA-2018:1415 web
- https://bugzilla.mozilla.org/show_bug.cgi?id=1452075 web
- https://github.com/mozilla/pdf.js package
- https://lists.debian.org/debian-lts-announce/2018/05/msg00007.html web
- https://security.gentoo.org/glsa/201810-01 web
- https://usn.ubuntu.com/3645-1 web
- https://www.debian.org/security/2018/dsa-4199 web
- https://www.mozilla.org/security/advisories/mfsa2018-11 web
- https://www.mozilla.org/security/advisories/mfsa2018-12 web
- http://www.securityfocus.com/bid/104136 web
- http://www.securitytracker.com/id/1040896 web