Skip to main content
← All vulnerabilities
CVE-2026-22787GHSA-W8X4-X68C-M6FC

html2pdf.js has a cross-site scripting vulnerability

Published
Last modified
published
Not listed in CISA KEV
Fix
Fixed in 0.14.0
None on Exploit-DB, Metasploit or GitHub
  • Exploitation: poc
  • Automatable: no
  • Technical impact: partial

Summary

html2pdf.js converts any webpage or element into a printable PDF entirely client-side. Prior to 0.14.0, html2pdf.js contains a cross-site scripting (XSS) vulnerability when given a text source rather than an element. This text is not sufficiently sanitized before being attached to the DOM, allowing malicious scripts to be run on the client browser and risking the confidentiality, integrity, and availability of the page's data. This vulnerability has been fixed in html2pdf.js@0.14.0.

Timeline

  1. CVE published
  2. CISA SSVC assessment

    Exploitation: poc · Automatable: no · Technical impact: partial

  3. Record last updated

Affected versions

  • eKoopmans html2pdf.js

    fixed in 0.14.0

  • html2pdf.jsnpm

    fixed in 0.14.0

References 5

GitHub · eKoopmans/html2pdf.js