CVE catalog

CVE-2021-3838

php-dompdf: CVE-2021-3838

[CVE catalog]

Severity
Medium
Published
Source
[NVD] · [CVE record]
EPSS
1.43% · Oct 25, 2026

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.

Vulnerable and fixed packages

Distribution-reported package versions and fixes. These do not depend on matching against the OpenFactory package catalog.

DistributionPackageReleaseVersionStatus
Debianphp-dompdfsid3.1.4+dfsg-2fixed
Debianphp-dompdfbookworm2.0.3+dfsg-1+deb12u1fixed
Ubuntuphp-dompdf22.040.6.2+dfsg-3.1vulnerable
Ubuntuphp-dompdf22.040.6.2+dfsg-3.1ubuntu0.1fixed
Ubuntuphp-dompdfpro0.6.2+dfsg-3vulnerable
Ubuntuphp-dompdfpro0.6.2+dfsg-3ubuntu0.18.04.1~esm1fixed
Ubuntuphp-dompdf20.040.6.2+dfsg-3vulnerable
Ubuntuphp-dompdf20.040.6.2+dfsg-3ubuntu0.20.04.1fixed
Ubuntuphp-dompdf22.040.6.2+dfsg-3.1vulnerable
Ubuntuphp-dompdf22.040.6.2+dfsg-3.1ubuntu0.1fixed

Fixed-version evidence

DistributionPackageTypeReleaseFixed versionUrgencyOriginBugs
Debianphp-dompdfsourcesid2.0.2+dfsg-1not yet assignedNot reportedNot reported
Debianphp-dompdfsourcebookworm2.0.2+dfsg-1not yet assignedNot reportedNot reported
Ubuntuphp-dompdfdeb22.040.6.2+dfsg-3.1ubuntu0.1Not reportedUSN-6277-2Not reported
Ubuntuphp-dompdfdebpro0.6.2+dfsg-3ubuntu0.18.04.1~esm1Not reportedUBUNTU-CVE-2021-3838Not reported
Ubuntuphp-dompdfdeb20.040.6.2+dfsg-3ubuntu0.20.04.1Not reportedUBUNTU-CVE-2021-3838Not reported
Ubuntuphp-dompdfdeb22.040.6.2+dfsg-3.1ubuntu0.1Not reportedUBUNTU-CVE-2021-3838Not reported

OpenFactory catalog packages

[Debian 12 (Bookworm)]

  • [php-dompdf]Fixed
    Details (2)
    • 2.0.3+dfsg-1+deb12u1 · all · bookworm

      Fixed · Fixed: 2.0.2+dfsg-1

      dsa · php-dompdf · debian · bookworm; dsa · php-dompdf · debian · 12

    • 2.0.3+dfsg-1+deb12u1 · all · bookworm

      Fixed · Fixed: 2.0.2+dfsg-1

      dsa · php-dompdf · debian · bookworm; dsa · php-dompdf · debian · 12

Observed:

References