Vulnerability · Published Jul 28, 2026 · Assigned by GitHub_M
CVE-2026-59942Dompdf: Denial of Service (DoS) via Resource Exhaustion using Oversized Image Bitmaps
Medium 6.3
In plain English
A medium-severity uncontrolled resource consumption in dompdf from dompdf. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 0.9% (higher than 60% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
Dompdf is an HTML to PDF converter for PHP. Versions 3.15 and prior are vulnerable to a Denial of Service (DoS) attack via resource exhaustion. An attacker can crash the PHP process by providing a specially crafted HTML document containing a single image with massive dimensions (e.g., 30,000x30,000 pixels). While Dompdf implements internal checks to validate image dimensions, these can be bypassed by using a high-entropy image (such as random noise) encoded in Base64 and wrapped in specific CSS containers. The vulnerability exists because the dimension validation happens early, but the resource allocation for calculating the object's bounding box and internal buffers during the rendering phase does not strictly limit the cumulative CPU time or memory usage for a single object that has passed the initial check. An unauthenticated remote attacker can cause a complete Denial of Service on the web server by submitting a crafted HTML string. This affects any application that allows users to provide HTML content or URLs that are subsequently converted to PDF using Dompdf. This issue has been fixed in version 3.16.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian:12 | php-dompdf | no fix listed | DEBIAN-CVE-2026-59942 |
| Packagist | dompdf/dompdf | 3.1.6 | GHSA-f5gf-2cj8-52g2 |
| Ubuntu:22.04:LTS | php-dompdf | no fix listed | UBUNTU-CVE-2026-59942 |
Affected products (as reported)
Weakness: CWE-400 · Vector: CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N
References
- https://github.com/dompdf/dompdf/security/advisories/GHSA-f5gf-2cj8-52g2 x_refsource_CONFIRM
- https://github.com/dompdf/dompdf/commit/7c65e7bbeccf146b2409740405af73949ad129d0 x_refsource_MISC
- https://github.com/dompdf/dompdf/commit/89164eaabe0bb50c462f0b24f740044ba5fb0f99 x_refsource_MISC
- https://github.com/dompdf/dompdf/releases/tag/v3.1.6 x_refsource_MISC