GHSA-r73j-pqj5-w3x7
CVE-2026-42310
How to Fix This Vulnerability
Upgrade to a fixed version
Remediation Steps
- 1Upgrade the package to version 12.2.0 or later
- 2Review and audit affected systems for potential exploitation
- 3Implement additional security controls if immediate patching is not possible
- 4Monitor for suspicious activity related to this vulnerability
Mitigation Strategies
- Immediate PatchingHigh
Apply security patches to version 12.2.0 immediately
- Network SegmentationMedium
Isolate affected systems from untrusted networks until patching is complete
- Monitoring and DetectionMedium
Implement enhanced monitoring for exploitation attempts and unusual behavior
Description
Impact
An attacker can supply a malicious PDF that causes the process to hang indefinitely, consuming 100% CPU and making the application unresponsive.
Patches
Patched version: 12.2.0.
PdfParser (introduced in Pillow 4.2.0) follows Prev pointers in PDF trailers to read cross-reference sections. If a trailer's Prev pointer references an offset that has already been processed — either pointing to itself or forming a longer cycle — the parser enters an infinite loop. Pillow now tracks previously processed trailer offsets and raises an error if a cycle is detected.
Workarounds
Use any version but the affected versions: >= 4.2.0, < 12.2.0
Resources
Impact Assessment
This medium-severity vulnerability could be exploited under certain conditions to compromise security controls or access sensitive information. Should be addressed in a timely manner.
CVSS v3.1 Metrics Breakdown
- attack Vector
- attack Complexity
- privileges Required
- user Interaction
- scope
- Unchanged
- confidentiality Impact
- Medium
- integrity Impact
- Medium
- availability Impact
- Medium
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:HVulnerability Timeline
- 2026-05-04T20:19:30ZVulnerability publishedpublished
- 2026-05-04T20:19:30ZPatches released: 12.2.0patched