Critical severity · published Nov 15, 2024
CVE-2021-3838
PHAR Deserialization in dompdf/dompdf
9.8
CVSS
1.4%
EPSS
No
On KEV
Description
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 vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
None
Confidentiality
High
Integrity
High
Availability
High
Scope
Unchanged
Exploitation
Is it being used?
Exploit prediction (EPSS)1.4% · higher than 73% of CVEs
Exploited in the wildNo evidence yet
CISA KEVNot listed
Ransomware campaign useNot known
Affected products
Which versions
DO
dompdf/dompdf · dompdf
before 2.0.0 · source: vendor
DO
Dompdf · Dompdf Project
before 2.0.0 · source: NVD, CISA
References
NVD
https://nvd.nist.gov/vuln/detail/CVE-2021-3838
CVE.org
https://www.cve.org/CVERecord?id=CVE-2021-3838
Patch
https://github.com/dompdf/dompdf/commit/99aeec1efec9213e87098d42eb09439e7ee0bb6a
Exploit
https://huntr.com/bounties/0bdddc12-ff67-4815-ab9f-6011a974f48e
More from dompdf/dompdf
9.8
CVE-2021-3902
Improper Restriction of XML External Entity Reference in dompdf/dompdf
