{"schemaVersion":3,"id":"CVE-2018-5158","aliases":["UBUNTU-CVE-2018-5158","DEBIAN-CVE-2018-5158","GHSA-7jg2-jgv3-fmr4"],"status":"published","duplicateOf":null,"title":null,"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 and Firefox < 60.","dates":{"published":"2018-06-11T21:00:00.000Z","modified":"2024-08-05T05:26:47.026Z","reserved":null,"kevAdded":[],"kevDue":[]},"cvss":{"headline":{"score":8.8,"severity":"high","version":"3.0","versionLabel":"v3.0","source":"NVD","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","computed":false,"selection":"backend-summary"},"metrics":[{"version":"3.0","versionLabel":"v3.0","source":"NVD","score":8.8,"severity":"high","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","exploitability":null,"impact":null,"computed":false},{"version":"2.0","versionLabel":"v2.0","source":"NVD","score":6.8,"severity":"medium","vector":"AV:N/AC:M/Au:N/C:P/I:P/A:P","exploitability":null,"impact":null,"computed":false},{"version":"3.0","versionLabel":"v3.0","source":"OSV · Ubuntu","score":8.8,"severity":"high","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","exploitability":7.2,"impact":9.8,"computed":true},{"version":"3.0","versionLabel":"v3.0","source":"OSV · Debian","score":8.8,"severity":"high","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","exploitability":7.2,"impact":9.8,"computed":true},{"version":"3.0","versionLabel":"v3.0","source":"OSV · Npm","score":8.8,"severity":"high","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","exploitability":7.2,"impact":9.8,"computed":true},{"version":"3.1","versionLabel":"v3.1","source":"wordfence","score":6.4,"severity":"medium","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N","exploitability":null,"impact":null,"computed":false}]},"epss":{"probability":0.1024,"percentile":0.95646,"severity":"medium","asOf":"2026-10-19T00:00:00.000Z","change":{"pp":-0.20499999999999963,"baselineDate":"2026-09-19T00:00:00.000Z","baselineScore":0.10445},"history":[{"date":"2026-09-14T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-15T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-16T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-17T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-18T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-19T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-20T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-21T00:00:00.000Z","score":0.12289,"percentile":null},{"date":"2026-09-22T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-23T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-24T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-25T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-26T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-27T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-28T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-29T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-30T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-01T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-02T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-03T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-04T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-05T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-06T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-07T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-08T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-09T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-10T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-11T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-12T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-13T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-14T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-15T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-16T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-17T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-18T00:00:00.000Z","score":0.1024,"percentile":null},{"date":"2026-10-19T00:00:00.000Z","score":0.1024,"percentile":0.95646}],"last30":[{"date":"2026-09-19T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-20T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-21T00:00:00.000Z","score":0.12289,"percentile":null},{"date":"2026-09-22T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-23T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-24T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-25T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-26T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-27T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-28T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-29T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-09-30T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-01T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-02T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-03T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-04T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-05T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-06T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-07T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-08T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-09T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-10T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-11T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-12T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-13T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-14T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-15T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-16T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-17T00:00:00.000Z","score":0.10445,"percentile":null},{"date":"2026-10-18T00:00:00.000Z","score":0.1024,"percentile":null},{"date":"2026-10-19T00:00:00.000Z","score":0.1024,"percentile":0.95646}]},"kev":{"state":"not-listed","entries":[],"listedCount":0,"totalCatalogs":3,"catalogs":[{"source":"cisa","label":"CISA","listed":false,"entry":null},{"source":"enisa","label":"ENISA","listed":false,"entry":null},{"source":"circl","label":"CIRCL","listed":false,"entry":null}]},"ransomware":{"state":"none-recorded","sources":[]},"exploits":[],"exploitCount":0,"weaknesses":[{"id":"CWE-94","name":"Improper Control of Generation of Code ('Code Injection')","description":"The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment.","type":"weakness","status":"Draft","abstraction":"Base","likelihoodOfExploit":"Medium","url":"https://cwe.mitre.org/data/definitions/94.html"},{"id":"CWE-79","name":"Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')","description":"The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.","type":"weakness","status":"Stable","abstraction":"Base","likelihoodOfExploit":"High","url":"https://cwe.mitre.org/data/definitions/79.html"}],"affected":[{"vendor":"canonical","product":"ubuntu_linux","name":"ubuntu linux","label":"ubuntu_linux","ecosystem":null,"cpePart":"o","purl":null,"purlType":null,"versions":[{"text":"14.04","noFixRecorded":false,"fixedIn":null},{"text":"16.04","noFixRecorded":false,"fixedIn":null},{"text":"17.10","noFixRecorded":false,"fixedIn":null},{"text":"18.04","noFixRecorded":false,"fixedIn":null}],"versionsText":"14.04 | 16.04 | 17.10 | 18.04","eol":{"isEol":true,"eolDate":"2019-04-02T00:00:00.000Z","matchMethod":"cpe","cycle":{"name":"14.04","label":"14.04 'Trusty Tahr' (LTS)","eolFrom":"2019-04-02T00:00:00.000Z","isLts":true,"isMaintained":false,"latestVersion":"14.04.6"},"product":{"name":"ubuntu","label":"Ubuntu","category":"os"}},"hubHref":"/vendor/canonical/ubuntu_linux"},{"vendor":"debian","product":"firefox-esr","name":"firefox-esr","label":"firefox-esr","ecosystem":"Debian","cpePart":null,"purl":"pkg:deb/debian/firefox-esr","purlType":"deb","versions":[{"text":"< 52.8.0esr-1","noFixRecorded":false,"fixedIn":null}],"versionsText":"< 52.8.0esr-1","eol":null,"hubHref":null},{"vendor":"ubuntu","product":"firefox","name":"firefox","label":"firefox","ecosystem":"Ubuntu","cpePart":null,"purl":"pkg:deb/ubuntu/firefox","purlType":"deb","versions":[{"text":"< 60.0+build2-0ubuntu0.14.04.1","noFixRecorded":false,"fixedIn":null},{"text":"< 60.0+build2-0ubuntu0.16.04.1","noFixRecorded":false,"fixedIn":null},{"text":"< 60.0+build2-0ubuntu1","noFixRecorded":false,"fixedIn":null}],"versionsText":"< 60.0+build2-0ubuntu0.14.04.1 | < 60.0+build2-0ubuntu0.16.04.1 | < 60.0+build2-0ubuntu1","eol":null,"hubHref":null},{"vendor":"debian","product":"debian_linux","name":"debian linux","label":"debian_linux","ecosystem":null,"cpePart":"o","purl":null,"purlType":null,"versions":[{"text":"7.0","noFixRecorded":false,"fixedIn":null},{"text":"8.0","noFixRecorded":false,"fixedIn":null},{"text":"9.0","noFixRecorded":false,"fixedIn":null}],"versionsText":"7.0 | 8.0 | 9.0","eol":{"isEol":true,"eolDate":"2018-05-31T00:00:00.000Z","matchMethod":"cpe","cycle":{"name":"7","label":"7 (Wheezy)","eolFrom":"2018-05-31T00:00:00.000Z","isLts":false,"isMaintained":false,"latestVersion":"7.11"},"product":{"name":"debian","label":"Debian","category":"os"}},"hubHref":"/vendor/debian/debian_linux"},{"vendor":"mozilla","product":"firefox","name":"firefox","label":"firefox","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"≥ unspecified, < 60","noFixRecorded":false,"fixedIn":null},{"text":"< 52.8.0","noFixRecorded":false,"fixedIn":null},{"text":"< 60.0","noFixRecorded":false,"fixedIn":null}],"versionsText":"≥ unspecified, < 60 | < 52.8.0 | < 60.0","eol":{"isEol":null,"eolDate":null,"matchMethod":"cpe","cycle":null,"product":{"name":"firefox","label":"Firefox","category":"app"}},"hubHref":"/vendor/mozilla/firefox"},{"vendor":"mozilla","product":"firefox_esr","name":"firefox esr","label":"firefox_esr","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"≥ unspecified, < 52.8","noFixRecorded":false,"fixedIn":null}],"versionsText":"≥ unspecified, < 52.8","eol":null,"hubHref":"/vendor/mozilla/firefox_esr"},{"vendor":"Npm","product":"pdfjs-dist","name":"pdfjs-dist","label":"pdfjs-dist","ecosystem":"Npm","cpePart":null,"purl":"pkg:npm/pdfjs-dist","purlType":"npm","versions":[{"text":"≥ 2.0.0, < 2.0.550","noFixRecorded":false,"fixedIn":null},{"text":"< 1.10.100","noFixRecorded":false,"fixedIn":null}],"versionsText":"≥ 2.0.0, < 2.0.550 | < 1.10.100","eol":null,"hubHref":null},{"vendor":"redhat","product":"enterprise_linux_desktop","name":"enterprise linux desktop","label":"enterprise_linux_desktop","ecosystem":null,"cpePart":"o","purl":null,"purlType":null,"versions":[{"text":"6.0","noFixRecorded":false,"fixedIn":null},{"text":"7.0","noFixRecorded":false,"fixedIn":null}],"versionsText":"6.0 | 7.0","eol":null,"hubHref":"/vendor/redhat/enterprise_linux_desktop"},{"vendor":"redhat","product":"enterprise_linux_server","name":"enterprise linux server","label":"enterprise_linux_server","ecosystem":null,"cpePart":"o","purl":null,"purlType":null,"versions":[{"text":"6.0","noFixRecorded":false,"fixedIn":null},{"text":"7.0","noFixRecorded":false,"fixedIn":null}],"versionsText":"6.0 | 7.0","eol":null,"hubHref":"/vendor/redhat/enterprise_linux_server"},{"vendor":"redhat","product":"enterprise_linux_server_aus","name":"enterprise linux server aus","label":"enterprise_linux_server_aus","ecosystem":null,"cpePart":"o","purl":null,"purlType":null,"versions":[{"text":"7.6","noFixRecorded":false,"fixedIn":null}],"versionsText":"7.6","eol":null,"hubHref":"/vendor/redhat/enterprise_linux_server_aus"},{"vendor":"redhat","product":"enterprise_linux_server_eus","name":"enterprise linux server eus","label":"enterprise_linux_server_eus","ecosystem":null,"cpePart":"o","purl":null,"purlType":null,"versions":[{"text":"7.5","noFixRecorded":false,"fixedIn":null},{"text":"7.6","noFixRecorded":false,"fixedIn":null}],"versionsText":"7.5 | 7.6","eol":null,"hubHref":"/vendor/redhat/enterprise_linux_server_eus"},{"vendor":"redhat","product":"enterprise_linux_server_tus","name":"enterprise linux server tus","label":"enterprise_linux_server_tus","ecosystem":null,"cpePart":"o","purl":null,"purlType":null,"versions":[{"text":"7.6","noFixRecorded":false,"fixedIn":null}],"versionsText":"7.6","eol":null,"hubHref":"/vendor/redhat/enterprise_linux_server_tus"},{"vendor":"redhat","product":"enterprise_linux_workstation","name":"enterprise linux workstation","label":"enterprise_linux_workstation","ecosystem":null,"cpePart":"o","purl":null,"purlType":null,"versions":[{"text":"6.0","noFixRecorded":false,"fixedIn":null},{"text":"7.0","noFixRecorded":false,"fixedIn":null}],"versionsText":"6.0 | 7.0","eol":null,"hubHref":"/vendor/redhat/enterprise_linux_workstation"},{"vendor":"wordpress","product":"algori-pdf-viewer","name":"Algori PDF Viewer","label":"algori-pdf-viewer","ecosystem":null,"cpePart":"a","purl":null,"purlType":null,"versions":[{"text":"≤ 1.0.7 (fixed in 1.0.8)","noFixRecorded":false,"fixedIn":"1.0.8"}],"versionsText":"≤ 1.0.7 (fixed in 1.0.8)","eol":null,"hubHref":null}],"affectedCount":14,"eol":{"hasEol":true,"count":2},"references":[{"url":"https://access.redhat.com/errata/RHSA-2018:1415","label":"access.redhat.com/errata/RHSA-2018:1415","hostname":"access.redhat.com","tags":["Vendor Advisory","X Refsource REDHAT","Third Party Advisory","WEB"]},{"url":"https://security.gentoo.org/glsa/201810-01","label":"security.gentoo.org/glsa/201810-01","hostname":"security.gentoo.org","tags":["Vendor Advisory","X Refsource GENTOO","Third Party Advisory","WEB"]},{"url":"https://access.redhat.com/errata/RHSA-2018:1414","label":"access.redhat.com/errata/RHSA-2018:1414","hostname":"access.redhat.com","tags":["Vendor Advisory","X Refsource REDHAT","Third Party Advisory","WEB"]},{"url":"https://www.mozilla.org/security/advisories/mfsa2018-11/","label":"www.mozilla.org/security/advisories/mfsa2018-11/","hostname":"www.mozilla.org","tags":["X Refsource CONFIRM","Vendor Advisory"]},{"url":"http://www.securitytracker.com/id/1040896","label":"www.securitytracker.com/id/1040896","hostname":"www.securitytracker.com","tags":["VDB Entry","X Refsource SECTRACK","Third Party Advisory","WEB"]},{"url":"https://www.debian.org/security/2018/dsa-4199","label":"www.debian.org/security/2018/dsa-4199","hostname":"www.debian.org","tags":["Vendor Advisory","X Refsource DEBIAN","Third Party Advisory","WEB"]},{"url":"https://usn.ubuntu.com/3645-1/","label":"usn.ubuntu.com/3645-1/","hostname":"usn.ubuntu.com","tags":["Vendor Advisory","X Refsource UBUNTU","Third Party Advisory"]},{"url":"https://lists.debian.org/debian-lts-announce/2018/05/msg00007.html","label":"lists.debian.org/debian-lts-announce/2018/05/msg00007.html","hostname":"lists.debian.org","tags":["Mailing List","X Refsource MLIST","Third Party Advisory","WEB"]},{"url":"https://bugzilla.mozilla.org/show_bug.cgi?id=1452075","label":"bugzilla.mozilla.org/show_bug.cgi?id=1452075","hostname":"bugzilla.mozilla.org","tags":["X Refsource CONFIRM","Issue Tracking","Vendor Advisory","WEB"]},{"url":"https://www.mozilla.org/security/advisories/mfsa2018-12/","label":"www.mozilla.org/security/advisories/mfsa2018-12/","hostname":"www.mozilla.org","tags":["X Refsource CONFIRM","Vendor Advisory"]},{"url":"http://www.securityfocus.com/bid/104136","label":"www.securityfocus.com/bid/104136","hostname":"www.securityfocus.com","tags":["VDB Entry","X Refsource BID","Third Party Advisory","WEB"]},{"url":"https://ubuntu.com/security/CVE-2018-5158","label":"ubuntu.com/security/CVE-2018-5158","hostname":"ubuntu.com","tags":["REPORT"]},{"url":"https://www.mozilla.org/en-US/security/advisories/mfsa2018-11/#CVE-2018-5158","label":"www.mozilla.org/en-US/security/advisories/mfsa2018-11/","hostname":"www.mozilla.org","tags":["REPORT"]},{"url":"https://ubuntu.com/security/notices/USN-3645-1","label":"ubuntu.com/security/notices/USN-3645-1","hostname":"ubuntu.com","tags":["Advisory"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2018-5158","label":"www.cve.org/CVERecord?id=CVE-2018-5158","hostname":"www.cve.org","tags":["REPORT"]},{"url":"https://security-tracker.debian.org/tracker/CVE-2018-5158","label":"security-tracker.debian.org/tracker/CVE-2018-5158","hostname":"security-tracker.debian.org","tags":["Advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2018-5158","label":"nvd.nist.gov/vuln/detail/CVE-2018-5158","hostname":"nvd.nist.gov","tags":["Advisory"]},{"url":"https://github.com/mozilla/pdf.js/pull/9659","label":"github.com/mozilla/pdf.js/pull/9659","hostname":"github.com","tags":["WEB"]},{"url":"https://github.com/mozilla/pdf.js/commit/2dc4af525d1612c98afcd1e6bee57d4788f78f97","label":"github.com/mozilla/pdf.js/commit/2dc4af525d1612c98afcd1e6bee57d4788f78f97","hostname":"github.com","tags":["WEB"]},{"url":"https://github.com/mozilla/pdf.js","label":"github.com/mozilla/pdf.js","hostname":"github.com","tags":["PACKAGE"]},{"url":"https://usn.ubuntu.com/3645-1","label":"usn.ubuntu.com/3645-1","hostname":"usn.ubuntu.com","tags":["WEB"]},{"url":"https://www.mozilla.org/security/advisories/mfsa2018-11","label":"www.mozilla.org/security/advisories/mfsa2018-11","hostname":"www.mozilla.org","tags":["WEB"]},{"url":"https://www.mozilla.org/security/advisories/mfsa2018-12","label":"www.mozilla.org/security/advisories/mfsa2018-12","hostname":"www.mozilla.org","tags":["WEB"]},{"url":"https://www.wordfence.com/threat-intel/vulnerabilities/id/0cd66329-098e-4adf-b66f-d82a47720629","label":"www.wordfence.com/threat-intel/vulnerabilities/id/0cd66329-098e-4adf-b66f-d82a47720629","hostname":"www.wordfence.com","tags":["Vendor Advisory"]}],"lineage":{"upstream":[],"downstream":["DLA-1376-1","DSA-4199-1","MGASA-2018-0248","MGASA-2018-0338","OPENSUSE-SU-2024:10600-1","OPENSUSE-SU-2024:14572-1","RHSA-2018:1414","RHSA-2018:1415","SUSE-SU-2018:1319-1","SUSE-SU-2018:1334-1","SUSE-SU-2018:1334-2","SUSE-SU-2018:2298-1","SUSE-SU-2019:2872-1","USN-3645-1"],"duplicates":[],"related":["OPENSUSE-SU-2024:10600-1","OPENSUSE-SU-2024:14572-1","SUSE-SU-2018:1319-1","SUSE-SU-2018:1334-1","SUSE-SU-2018:1334-2","SUSE-SU-2018:2298-1","SUSE-SU-2019:2872-1","USN-3645-1"]},"timeline":[{"kind":"published","date":"2018-06-11T21:00:00.000Z","label":"Published","detail":"Vulnerability first disclosed.","source":null},{"kind":"modified","date":"2024-08-05T05:26:47.026Z","label":"Last modified","detail":"Vulnerability information updated.","source":null}],"risk":{"score":37,"level":"medium","profile":"Default","thresholds":{"critical":75,"high":50,"medium":25,"low":10}},"meta":{"dataAsOf":"2026-10-19T16:13:49.548Z","stale":false,"partial":false}}