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

Published Feb 14, 2023
·
Updated

[Unknown description]

Other sources

Deserialization of Untrusted Data using PHAR deserialization

Debian

DomPDF before version 2.0.0 is vulnerable to PHAR (PHP Archive) deserialization due to a lack of checking on the protocol before passing it into the filegetcontents() 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.

GitHub

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 filegetcontents() 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.

MITRE

Affected Software

8 affected componentsFixes available
ubuntu/php-dompdf<2.0.2+dfsg-1, <2.0.0
2.0.2+dfsg-12.0.0
ubuntu/php-dompdf<0.6.1+dfsg-2ubuntu1+
0.6.1+dfsg-2ubuntu1+
ubuntu/php-dompdf<0.6.2+dfsg-3ubuntu0.18.04.1~
0.6.2+dfsg-3ubuntu0.18.04.1~
ubuntu/php-dompdf<0.6.2+dfsg-3ubuntu0.20.04.1
0.6.2+dfsg-3ubuntu0.20.04.1
ubuntu/php-dompdf<0.6.2+dfsg-3.1ubuntu0.1
0.6.2+dfsg-3.1ubuntu0.1
debian/php-dompdf<=0.6.2+dfsg-3, <=0.6.2+dfsg-3.1
0.6.2+dfsg-3+deb10u22.0.3+dfsg-12.0.4+dfsg-1
composer/dompdf/dompdf<2.0.0
2.0.0
Dompdf Project Dompdf<2.0.0

Event History

Feb 14, 2023
CVE Published
via Ubuntu·12:00 AM
Nov 15, 2024
CVE Published
via MITRE·10:51 AM
Data Sourced
via MITRE·10:51 AM
DescriptionSeverityWeakness
Advisory Published
via GitHub·12:31 PM

Parent advisories

This vulnerability appears in the following advisories.

Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is CVE-2021-3838?

CVE-2021-3838 is a vulnerability related to the deserialization of untrusted data using PHAR deserialization.

2

How does CVE-2021-3838 affect software?

CVE-2021-3838 affects the php-dompdf package in various versions of Debian and Ubuntu.

3

What is the severity of CVE-2021-3838?

The severity of CVE-2021-3838 is yet to be determined, but it is recommended to apply the available remedies to mitigate the vulnerability.

4

How can I fix CVE-2021-3838?

To fix CVE-2021-3838, it is recommended to update the php-dompdf package to the specified versions or apply the relevant security patches provided by the distribution.

5

Where can I find more information about CVE-2021-3838?

You can find more information about CVE-2021-3838 on the GitHub page of dompdf and the related reference links.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203