Deserialization in Dompdf Dompdf/dompdf
CVE-2021-3838
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.
Vulnerability class: Insecure Deserialization
Published · last modified .
CVSS v3 metric
CVSS v3 base score 9.8 (Critical). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H.
EPSS exploit prediction
EPSS 0.014, 73.5th percentile (scored ); unchanged over 30 days. About EPSS.
Affected products
- Dompdf Dompdf/dompdf — versions unspecified
- Dompdf Project
Weakness classification (CWE)
Public exploits and proof-of-concept code
Also mentioned in 2 other repositories (20142995/nuclei-templates, cyb3r-w0lf/nuclei-template-collection). These reference the CVE in a list, notes or a scanner and are not exploit code for it.
References
- huntr.com/bounties/0bdddc12-ff67-4815-ab9f-6011a974f48e (Exploit, Patch, Third Party Advisory, Issue Tracking)
- github.com/dompdf/dompdf/commit/99aeec1efec9213e87098d42eb09439e7ee0bb6a (Patch)