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.
Affected products
| Vendor | Product | Affected | Fixed |
|---|---|---|---|
| dompdf | dompdf/dompdf | unspecified – < 2.0.0 | 2.0.0 |
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 12 | php-dompdf | 2.0.2+dfsg-1 | — |
| Debian 11 | php-dompdf | 0.6.2+dfsg-3.1+deb11u1 | DLA-4427-1 |
| Debian 10 | php-dompdf | 0.6.2+dfsg-3+deb10u1 | DLA-3495-2, DLA-3495-1 |
Ubuntu
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu 22.04 LTS | php-dompdf | 0.6.2+dfsg-3.1ubuntu0.1 | USN-6277-2 |
| Ubuntu 20.04 LTS | php-dompdf | 0.6.2+dfsg-3ubuntu0.20.04.1 | USN-6277-1 |
Show 2 more (older releases, extended support, other products)Fewer releases
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Ubuntu Pro 18.04 LTS | php-dompdf | 0.6.2+dfsg-3ubuntu0.18.04.1~esm1 | USN-6277-1 |
| Ubuntu Pro 16.04 LTS | php-dompdf | 0.6.1+dfsg-2ubuntu1+esm1 | USN-6277-1 |
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| Packagist | dompdf/dompdf | < 2.0.0 | 2.0.0 | GHSA-577p-7j7h-2jgf |
Advisories 5
- USN-6277-1 php-dompdf vulnerabilities Ubuntu Security Notices (USN) · Jun 25, 2026
- USN-6277-2 php-dompdf vulnerabilities Ubuntu Security Notices (USN) · Apr 27, 2026
- DLA-3495-2 php-dompdf - regression update Debian Security (DSA / DLA) · Mar 9, 2026
- DLA-3495-1 php-dompdf - security update Debian Security (DSA / DLA) · Mar 9, 2026
- DLA-4427-1 php-dompdf - security update Debian Security (DSA / DLA) · Dec 30, 2025