p PatchFirst

CVE-2021-3838

CVE-2021-3838 · PHAR Deserialization in dompdf/dompdf

This page contains facts from public vulnerability sources. Check the original advisory before updating.

DomPDF before version 2.0.0 is vulnerable to PHAR deserialization due to a lack of checking on the protocol before passing it into the file_get_contents() function. An attacker who can upload files of any type to the server can pass in the phar:// protocol to unserialize the uploaded file and instantiate arbitrary PHP objects. This can lead to remote code execution, especially when DOMPdf is used with frameworks with documented POP chains like Laravel or vulnerable developer code.

CVSS 9.8 · Critical · EPSS 1.4% · Fix available

Published
Updated

Stack: system · php

Affected products and versions

  • dompdf/dompdf

    Versions
    • ≥ unspecified, < 2.0.0: Affected (custom)

    Update to 2.0.0

  • php-dompdf Debian:12

    Affected ranges
    • ECOSYSTEM: < 2.0.2+dfsg-1

    Update to 2.0.2+dfsg-1

  • dompdf/dompdf Packagist

    Versions
    • v0.6.0
    • v0.6.1
    • v0.6.2
    • v0.7.0
    • v0.7.0-beta
    • v0.7.0-beta2
    • v0.7.0-beta3
    • v0.8.0
    • v0.8.1
    • v0.8.2
    • v0.8.3
    • v0.8.4
    • v0.8.5
    • v0.8.6
    • v1.0.0
    • v1.0.1
    • v1.0.2
    • v1.1.0
    • v1.1.1
    • v1.2.0
    • v1.2.1
    • v1.2.2
    Affected ranges
    • ECOSYSTEM: < 2.0.0

    Update to 2.0.0

  • php-dompdf Ubuntu:Pro:16.04:LTS

    Versions
    • 0.6.1+dfsg-2
    • 0.6.1+dfsg-2build1
    • 0.6.1+dfsg-2ubuntu1
    Affected ranges
    • ECOSYSTEM: < 0.6.1+dfsg-2ubuntu1+esm1

    Update to 0.6.1+dfsg-2ubuntu1+esm1

  • php-dompdf Ubuntu:Pro:18.04:LTS

    Versions
    • 0.6.2+dfsg-3
    Affected ranges
    • ECOSYSTEM: < 0.6.2+dfsg-3ubuntu0.18.04.1~esm1

    Update to 0.6.2+dfsg-3ubuntu0.18.04.1~esm1

  • php-dompdf Ubuntu:20.04:LTS

    Versions
    • 0.6.2+dfsg-3
    Affected ranges
    • ECOSYSTEM: < 0.6.2+dfsg-3ubuntu0.20.04.1

    Update to 0.6.2+dfsg-3ubuntu0.20.04.1

  • php-dompdf Ubuntu:22.04:LTS

    Versions
    • 0.6.2+dfsg-3.1
    Affected ranges
    • ECOSYSTEM: < 0.6.2+dfsg-3.1ubuntu0.1

    Update to 0.6.2+dfsg-3.1ubuntu0.1

Original sources

Check your server →