Skip to content

v1.1.0

Latest

Choose a tag to compare

@jonaslejon jonaslejon released this 27 Nov 09:53
· 3 commits to main since this release
v1.1.0
294467a

Adds a test case for a 2026 PDF.js vulnerability. 70 PDF generators plus the SVG case.

Added

  • test49.pdf — CVE-2026-16633, the PDF.js scripting-sandbox bridge. Document JavaScript recovers the raw Field through the scripting API proxy's inherited valueOf, then uses its private _send() to store a forged annotation editor whose comment rich text the viewer renders as DOM.

    It is a detection probe: the forged rich text fetches a remote resource so your Collaborator host sees a hit. It carries no script-execution payload.

    Validated against two real builds rather than by inspection:

    Build CSP Callback
    pdfjs-dist 6.1.200 none fires (obfuscation 0 and 4)
    pdfjs-dist 6.2.108 none none
    pdfjs-dist 6.1.200 stock viewer.html blocked by img-src 'self'

    Under a CSP the forged DOM is still built and only the outbound request is stopped, so a CSP mitigates exfiltration here rather than injection.

    Affects pdfjs-dist 5.6.205–6.2.107. Needs enableScripting (the default), the comment feature enabled, and no CSP restricting img-src; the trigger is the reader opening the forged comment. Firefox ≥ 153 is unaffected because of its own CSP change.

Changed

  • Obfuscation level 4 now treats a payload containing pdfjs_internal_editor_ as browser-targeted, so it gets the String.fromCharCode wrapper instead of Acrobat's util.streamFromString, which PDF.js does not implement. Without this, level 4 silently broke test49 under PDF.js.
  • The README banner is served from docs/ in this repository instead of being hot-linked from an external host.
$ python3 malicious-pdf.py --version
malicious-pdf.py 1.1.0

See CHANGELOG.md for the full list.