[ CVE-2026-112894 · Published 19 Oct 2026 ]
Pillow: Quadratic-time DoS in PDF save_all (PdfParser.next_object_id)
CVSS 8.7
EPSS <1%Fix available
[ Why it matters ]Priority signals
- Public proof-of-concept exploit exists (CISA SSVC)
[ Description ]Official description
Pillow is a Python imaging library. From 5.1.0 until 13.0.0, Pillow takes quadratic time to reserve PDF object identifiers when saving many frames with save_all enabled. PdfParser.next_object_id() repeatedly rebuilds and scans all previously reserved identifiers for every object. An attacker can supply a multi-frame image, including a small APNG with a large declared frame count, to an application that converts it to a multipage PDF. This can consume excessive CPU and deny service. This issue is fixed in version 13.0.0.
[ Fixes ]Fixes and patches
- Pillow 13.0.0Fixed version · GitHub Advisories · pip package Pillow: upgrade to 13.0.0 or later (affected >= 5.1.0, < 13.0.0)
[ Packages ]Affected open-source packages
- Pillow pipAffected >= 5.1.0, < 13.0.0 · fixed in 13.0.0 · GHSA-jg86-v3jv-hrpm