Vulnerability · Published Nov 12, 2025 · Assigned by GitHub_M
CVE-2025-64503[BIGSLEEP-434615384] cups-filters 1.x: out of bounds write in pdftoraster
Medium 4.0
In plain English
A medium-severity out-of-bounds write in cups-filters from OpenPrinting. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 0.2% (higher than 14% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.
Official description
cups-filters contains backends, filters, and other software required to get the cups printing service working on operating systems other than macos. In cups-filters prior to 1.28.18, by crafting a PDF file with a large `MediaBox` value, an attacker can cause CUPS-Filter 1.x’s `pdftoraster` tool to write beyond the bounds of an array. First, a PDF with a large `MediaBox` width value causes `header.cupsWidth` to become large. Next, the calculation of `bytesPerLine = (header.cupsBitsPerPixel * header.cupsWidth + 7) / 8` overflows, resulting in a small value. Then, `lineBuf` is allocated with the small `bytesPerLine` size. Finally, `convertLineChunked` calls `writePixel8`, which attempts to write to `lineBuf` outside of its buffer size (out of bounds write). In libcupsfilters, the maintainers found the same `bytesPerLine` multiplication without overflow check, but the provided test case does not cause an overflow there, because the values are different. Commit 50d94ca0f2fa6177613c97c59791bde568631865 contains a patch, which is incorporated into cups-filters version 1.28.18.
Affected packages & fixed versions
| Ecosystem | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian:12 | cups-filters | 1.28.17-3+deb12u2 | DEBIAN-CVE-2025-64503 |
| Debian:13 | cups-filters | 1.28.17-6+deb13u1 | DEBIAN-CVE-2025-64503 |
| Debian:14 | cups-filters | 1.28.17-7 | DEBIAN-CVE-2025-64503 |
| Debian:13 | libcupsfilters | 2.0.0-3+deb13u1 | DEBIAN-CVE-2025-64503 |
| Debian:14 | libcupsfilters | 2.1.1-2 | DEBIAN-CVE-2025-64503 |
| Ubuntu:22.04:LTS | cups-filters | 1.28.15-0ubuntu1.5 | USN-7878-1 |
| Ubuntu:22.04:LTS | cups-filters | 1.28.15-0ubuntu1.5 | UBUNTU-CVE-2025-64503 |
| Ubuntu:24.04:LTS | cups-filters | 2.0.0-0ubuntu4.1 | USN-7878-1 |
| Ubuntu:25.10 | cups-filters | 2.0.1-0ubuntu3.25.10.1 | USN-7878-1 |
| Ubuntu:24.04:LTS | libcupsfilters | 2.0.0-0ubuntu7.2 | USN-7877-1 |
| Ubuntu:24.04:LTS | libcupsfilters | 2.0.0-0ubuntu7.2 | UBUNTU-CVE-2025-64503 |
| Ubuntu:25.10 | libcupsfilters | 2.1.1-0ubuntu3.1 | UBUNTU-CVE-2025-64503 |
| Ubuntu:25.10 | libcupsfilters | 2.1.1-0ubuntu3.1 | USN-7877-1 |
Affected products (as reported)
| Vendor | Product | Versions |
|---|---|---|
| OpenPrinting | cups-filters | cups-filters < 1.28.18libcupsfilters >= 2.0.0, < 2.1.2 |
Weakness: CWE-787 · Vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
References
- https://github.com/OpenPrinting/cups-filters/security/advisories/GHSA-893j-2wr2-wrh9 x_refsource_CONFIRM
- https://github.com/OpenPrinting/cups-filters/commit/50d94ca0f2fa6177613c97c59791bde568631865 x_refsource_MISC
- https://github.com/OpenPrinting/cups-filters/blob/aea8d0db017e495b0204433ebdb0e86b4871094c/filter/pdftoraster.cxx#L1620 x_refsource_MISC
- https://github.com/OpenPrinting/cups-filters/blob/aea8d0db017e495b0204433ebdb0e86b4871094c/filter/pdftoraster.cxx#L1880 x_refsource_MISC
- https://github.com/OpenPrinting/libcupsfilters/blob/1dd86d835b27ed149b66aee1a4853d1db8a1f44c/cupsfilters/pdftoraster.cxx#L1790 x_refsource_MISC
- http://www.openwall.com/lists/oss-security/2025/11/12/2