CVE-2018-5158: The PDF viewer does not sufficiently sanitize PostScript calculator functions, allowing malicious JavaScript to be injected through a…
Noroxi assessment
Priority: Monitor (action score 38/100)
- Public proof-of-concept code exists (GitHub); there is no record of exploitation in the wild.
- Probability of exploitation in the next 30 days: 10.2% (FIRST EPSS); higher than 95.7% of all records.
- Anyone who can reach it over the internet can trigger it. No account or password is required. A user must open a link or visit a page. No special conditions are required; it is repeatable.
- Fixed version: firefox-esr (Debian:12) 52.8.0esr-1; firefox-esr (Debian:7) 52.8.0esr-1~deb7u1; firefox-esr (Debian:8) 52.8.0esr-1~deb8u1.
Low priority for now. Upgrade to firefox-esr (Debian:12) 52.8.0esr-1; firefox-esr (Debian:7) 52.8.0esr-1~deb7u1; firefox-esr (Debian:8) 52.8.0esr-1~deb8u1 or later.
Generated automatically from the record's data: CVSS (NVD and CNA), CISA KEV and SSVC, FIRST EPSS, exploit sources, fixed versions. How we calculate it
Primary sources: NVD · CVE.org · FIRST EPSS
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 and Firefox < 60.
- Published
- Jun 11, 2018
- Updated
- Jun 16, 2026
- EPSS
- 10.2% · 95th percentile
- CWE
- CWE-94
Report tools
Action score
38
Low priority for now.
- CVSS
- 35 / 40 · 8.8 / 10
- CISA KEV
- 0 / 30 · Not listed
- EPSS
- 3 / 30 · 10.2%
Get told when this record changes
- Not in KEV: no record of exploitation in the wild
- Proof of concept exists, no weaponized module
- A fix has been released
If any of these changes, we'll tell you in the daily email digest.
Is the PDF.js on your site affected?Scan JavaScript libraries
Is your version affected? Check itNoroxi analysis
What does it mean in your environment?
The assessment above is generated automatically from the record's data; it doesn't know your environment. Our team verifies on your systems whether this vulnerability is actually exploitable and which mitigation is enough.
We use this product, ask for helpAffected systems
Is your version affected?
Pick the product and type the version you run. It's compared with this record's version ranges in your browser; the version isn't sent anywhere.
| Vendor | Product | CPE |
|---|---|---|
| debian | debian linux | cpe:2.3:o:debian:debian_linux |
| redhat | enterprise linux desktop | cpe:2.3:o:redhat:enterprise_linux_desktop |
| redhat | enterprise linux server | cpe:2.3:o:redhat:enterprise_linux_server |
| redhat | enterprise linux server aus | cpe:2.3:o:redhat:enterprise_linux_server_aus |
| redhat | enterprise linux server eus | cpe:2.3:o:redhat:enterprise_linux_server_eus |
| redhat | enterprise linux server tus | cpe:2.3:o:redhat:enterprise_linux_server_tus |
| redhat | enterprise linux workstation | cpe:2.3:o:redhat:enterprise_linux_workstation |
| mozilla | firefox | cpe:2.3:a:mozilla:firefox |
| canonical | ubuntu linux | cpe:2.3:o:canonical:ubuntu_linux |
Is the PDF.js on your site affected?
The free JavaScript library scanner reads the PDF.js version from the files your site loads, matches this record and other known vulnerabilities, and gives the safe version on the same branch. If the version can't be read, it says so. No account needed.
Scan JavaScript librariesVersions reported by the vendor
Affected version ranges reported by the assigning authority (mozilla). Independent of NVD's CPE analysis and usually ahead of it.
Mozilla Firefox
- unspecified and later · before 60affected
Mozilla Firefox ESR
- unspecified and later · before 52.8affected
Affected versions · NVD (19)
NVD version ranges (for catalog products). Add the product to your stack with a version and matching uses these.
- canonical ubuntu linux14.04
- canonical ubuntu linux16.04
- canonical ubuntu linux17.10
- canonical ubuntu linux18.04
- debian debian linux7.0
- debian debian linux8.0
- debian debian linux9.0
- mozilla firefoxbefore 52.8.0
- mozilla firefoxbefore 60.0
- redhat enterprise linux desktop6.0
- redhat enterprise linux desktop7.0
- redhat enterprise linux server6.0
- redhat enterprise linux server7.0
- redhat enterprise linux server aus7.6
- redhat enterprise linux server eus7.5
- redhat enterprise linux server eus7.6
- redhat enterprise linux server tus7.6
- redhat enterprise linux workstation6.0
- redhat enterprise linux workstation7.0
Package-level exposure
OSV and GitHub Advisory data: ecosystem, package and range. SBOM matching uses this table.
| Ecosystem | Package | Affected range | Fix |
|---|---|---|---|
| Debian:12 | firefox-esr | before 52.8.0esr-1 | 52.8.0esr-1 |
| Debian:7 | firefox-esr | before 52.8.0esr-1~deb7u1 | 52.8.0esr-1~deb7u1 |
| Debian:8 | firefox-esr | before 52.8.0esr-1~deb8u1 | 52.8.0esr-1~deb8u1 |
| Debian:9 | firefox-esr | before 52.8.0esr-1~deb9u1 | 52.8.0esr-1~deb9u1 |
| npm | pdfjs-dist | from 2.0.0 · before 2.0.550 | 2.0.550 |
| npm | pdfjs-dist | before 1.10.100 | 1.10.100 |
| Red Hat:enterprise_linux:6::client | firefox | before 0:52.8.0-1.el6_9 | 0:52.8.0-1.el6_9 |
| Red Hat:enterprise_linux:6::client | firefox-debuginfo | before 0:52.8.0-1.el6_9 | 0:52.8.0-1.el6_9 |
| Red Hat:enterprise_linux:7::client | firefox | before 0:52.8.0-1.el7_5 | 0:52.8.0-1.el7_5 |
| Red Hat:enterprise_linux:7::client | firefox-debuginfo | before 0:52.8.0-1.el7_5 | 0:52.8.0-1.el7_5 |
| SUSE:Linux Enterprise Module for Desktop Applications 15 | MozillaFirefox | before 52.9.0esr-3.7.12 | 52.9.0esr-3.7.12 |
| SUSE:Linux Enterprise Software Development Kit 11 SP4 | MozillaFirefox | before 52.8.0esr-72.32.1 | 52.8.0esr-72.32.1 |
| SUSE:OpenStack Cloud 7 | MozillaFirefox | before 52.8.0esr-109.31.2 | 52.8.0esr-109.31.2 |
Same product
debian: all recordsOther highest-scoring records for the same primary product.
- CVE-2016-9079A use-after-free vulnerability in SVG Animation has been discovered.KEV86Now
- CVE-2024-44308The issue was addressed with improved checks.KEV68This week
- CVE-2021-25216A second vulnerability in BIND's GSSAPI security policy negotiation can be targeted by a buffer overflow attack64This week
Published before and after this one in the same product
- ← EarlierCVE-2018-5154Jun 11, 2018 · A use-after-free vulnerability can occur while enumerating attributes during SVG animations with clip paths.40Plan
- ← EarlierCVE-2018-5155Jun 11, 2018 · A use-after-free vulnerability can occur while adjusting layout during SVG animations with text paths.40Plan
- Later →CVE-2018-5159Jun 11, 2018 · An integer overflow can occur in the Skia library due to 32-bit integer use in an array without integer overflow checks, resulting in…45Plan
Remediation
Which version to upgrade to
Fix versions compiled from the vendor, package registries and Microsoft. Verify the vendor's note before upgrading.
| Product / package | Fixed version | Source |
|---|---|---|
| debian:firefox-esr | 52.8.0esr-1 · Debian:12 | Package registry (OSV) |
| npm:pdfjs-dist | 1.10.100 | Package registry (OSV) |
| npm:pdfjs-dist | 2.0.550 | Package registry (OSV) |
| red hat:firefox | 0:52.8.0-1.el6_9 · Red Hat:enterprise_linux:6::client | Package registry (OSV) |
| red hat:firefox-debuginfo | 0:52.8.0-1.el6_9 · Red Hat:enterprise_linux:6::client | Package registry (OSV) |
| suse:MozillaFirefox | 52.8.0esr-72.32.1 · SUSE:Linux Enterprise Software Development Kit 11 SP4 | Package registry (OSV) |
Exploit status
Proof of concept available
A public proof of concept or detection signature exists. Exploit knowledge is out there; don't delay patching.
Evidence
- Proof-of-concept repository on GitHub ×1
Noroxi does not host or link to exploit code. Metasploit module names and Nuclei template ids are shown (names, not code); Exploit-DB entries and PoC repositories are given as counts only.
| Source | Kind | Date |
|---|---|---|
| Proof-of-concept repository on GitHub | stars:1 | 2024-01-26 |
Research context
For pentesters and researchers: attack profile, score disagreement, timeline, patch commits, credits, variant and chain candidates, bug bounty scope. All derived from existing data; no exploit code.
Timeline
From publication to today: proof of concept, Metasploit module, CISA KEV and fix record. Dates are as reported by the sources.
- Published
- First PoC+2054 d
- TodayNov 16, 2026+3079 d
FIRST EPSS daily score; only changes of 0.01 or more are recorded (step chart).
Not on record for this CVE: patch commit or PR link · researcher credit · variant or chain candidate · public bounty program.
Technical details
Attack conditions
- Anyone who can reach it over the internet can trigger it.
- No account or password is required.
- A user must open a link or visit a page.
- No special conditions are required; it is repeatable.
If successful
- Confidentiality
- high · data can be read
- Integrity
- high · data or configuration can be modified
- Availability
- high · the service can be disrupted
- Attack vector
- Network
- Attack complexity
- Low
- Privileges required
- None
- User interaction
- Required
- Scope
- Unchanged
- Confidentiality impact
- High
- Integrity impact
- High
- Availability impact
- High
Weakness class (CWE)
CWE-94 · Improper Control of Generation of Code ('Code Injection')CVSS vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
nvd-primary
Attack context
MITRE CAPEC attack patterns and ATT&CK techniques for this weakness class (CWE). A starting point for detection rules and threat hunting.
Attack patterns (CAPEC)
Change log (1)
- Fix✗ → ✓
For records you follow, these changes also arrive as notifications. →
References
Show all references (10 more)Show less
- www.securitytracker.com/id/1040896
- access.redhat.com/errata/RHSA-2018:1414
- access.redhat.com/errata/RHSA-2018:1415
- bugzilla.mozilla.org/show_bug.cgi?id=1452075
- lists.debian.org/debian-lts-announce/2018/05/msg00007.html
- security.gentoo.org/glsa/201810-01
- usn.ubuntu.com/3645-1/
- www.debian.org/security/2018/dsa-4199
- www.mozilla.org/security/advisories/mfsa2018-11/
- www.mozilla.org/security/advisories/mfsa2018-12/
Vendor advisories and official records. Exploit/PoC links are deliberately left out.