Skip to main content

Pillow EUVDEUVD-2026-41899

| CVE-2026-54059 HIGH
Memory Allocation with Excessive Size Value (CWE-789)
2026-07-06 GitHub_M GHSA-8v84-f9pq-wr9x PYSEC-2026-2253
7.5
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Identify service that loads untrusted PCF fonts
  2. Delivery
    Submit crafted PCF with oversized METRICS dimensions
  3. Exploit
    Pillow reads glyph size, skips bomb check
  4. Execution
    Image.frombytes() requests huge allocation
  5. Impact
    Memory exhausted, worker/host crashes (DoS)

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Memory allocation limits
Exploitation Conditions

Exploitation requires the target application to load an attacker-controlled PCF (X11 Portable Compiled Format) bitmap font through Pillow's PcfFontFile loader - for example via ImageFont/PcfFontFile on an uploaded or fetched .pcf file. The concrete prerequisite is that untrusted PCF font data reaches _load_bitmaps(); applications that never parse external PCF fonts are not exposed. Limiting factors: only the PCF code path is affected (not JPEG/PNG/other formats), the impact is confined to memory-exhaustion denial of service with no code execution or data disclosure, and reachability depends on the application deliberately accepting third-party fonts. No authentication is required at the CVSS level (PR:N), but the practical attack surface is narrowed to font-processing features.

Impact

The NVD CVSS 3.1 vector (AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H, base 7.5) rates this High, driven entirely by the availability impact - confidentiality and integrity are explicitly N, so despite the 'Information Disclosure' tag this is a denial-of-service issue, a conflict worth flagging. The AV:N/PR:N/UI:N metrics assume the crafted PCF font can reach the parser without authentication or user interaction, which is only true for applications that accept and load untrusted PCF font files; in practice PCF font loading is an uncommon, application-specific path, which tempers real-world exposure. No EPSS score, SSVC decision, KEV listing, or POC was provided, so there is no evidence of active or automatable exploitation - this reads as a genuine but bounded DoS bug that merits routine patching rather than emergency response, unless the deployment specifically ingests attacker-supplied fonts.

Exploit ScenarioDerived

An attacker uploads a maliciously crafted PCF font file to a web service that uses Pillow to render text or preview fonts; when the service calls PcfFontFile to load the glyphs, the inflated METRICS dimensions trigger a massive Image.frombytes() allocation that exhausts memory and crashes the worker or host. Because the flaw is network-reachable (AV:N) with low complexity and no authentication or user interaction required in such a pipeline, repeated submissions can produce sustained denial of service. No public POC has been identified at time of analysis.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 06, 2026

Uncontrolled memory allocation in the Python Pillow imaging library (all versions prior to 12.3.0) allows a crafted PCF bitmap font to exhaust process memory and crash the host application. The PcfFontFile bitmap loader trusts attacker-supplied glyph dimensions from the font's METRICS section and hands them straight to Image.frombytes() while skipping Pillow's decompression-bomb guard. There is no public exploit identified at time of analysis and it is not listed in CISA KEV; the flaw is an availability-only denial of service (CVSS 7.5), not the information disclosure implied by the source tag.

RemediationAI

Upgrade to Pillow 12.3.0 or later, which adds the missing Image._decompression_bomb_check() call to _load_bitmaps() (fix commit 0a263e6264aa5399988d9acd3bbfbca2ca3ec77d). This is a vendor-released patch: version 12.3.0. If an immediate upgrade is not possible, avoid loading untrusted or user-supplied PCF font files, or restrict font loading to a vetted allowlist of trusted fonts, since the vulnerable path is only reachable through PCF parsing; where feasible, run image/font processing in a memory-limited sandbox (e.g., cgroup/ulimit-bounded worker) so an oversized allocation kills only the worker rather than the whole service - the trade-off being added operational complexity and potential loss of throughput. Consult GHSA-8v84-f9pq-wr9x and the 12.3.0 release notes for details.

Affected VersionsENISA

Pillow < 12.3.0

Affected Packages

pypi pillow fix: 12.3.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Pillow is the de facto Python imaging library used for decoding, manipulating and rendering images and fonts. The defect is in PIL/PcfFontFile.py, which parses X11 PCF (Portable Compiled Format) bitmap fonts. In _load_bitmaps(), glyph width/height values are read from the font's METRICS section and passed directly to Image.frombytes() without first invoking Image._decompression_bomb_check(), the safeguard Pillow normally uses to reject implausibly large image dimensions. The root cause maps to CWE-789 (Memory Allocation with Excessive Size Value): a size field controlled by untrusted input drives an unbounded allocation. Because the dimensions come from the font file rather than a validated source, a single crafted PCF file can request an allocation far larger than any legitimate glyph.

Know when Pillow gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 7.5 HIGH
AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
vuln.today AI 7.5 HIGH

Untrusted PCF font data can arrive over the network with no auth or interaction, but impact is memory-exhaustion DoS only, so C/I:N and A:H.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
SUSE HIGH
Red Hat 7.5 HIGH

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High

Lifecycle Timeline

1
Patch available
Jul 06, 2026 - 20:02 EUVD

DescriptionCVE.org

Pillow is a Python imaging library. Prior to 12.3.0, PIL/PcfFontFile.py _load_bitmaps() read glyph dimensions from the PCF METRICS section and passed them directly to Image.frombytes() without calling Image._decompression_bomb_check(), allowing crafted PCF font data to cause excessive memory allocation. This issue is fixed in version 12.3.0.

Blast Radius

ecosystem impact
† from your stack dependencies † transitive graph · vuln.today resolves 4-path depth
  • 2,739 pypi packages depend on pillow (1,116 direct, 1,651 indirect)

Ecosystem-wide dependent count for version 12.3.0.

Executive ViewAI

Why It Matters

Python Pillow, a critical image processing library used across enterprise systems, contains a high-severity denial-of-service vulnerability in its PCF font file handler that allows crafted fonts to exhaust process memory and crash applications. No public exploit code has been identified; however, the vulnerability affects all versions prior to 12.3.0 and directly threatens service availability and business continuity.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.3%
Top 75% exploitable
Prevalence
High
Pillow is one of the most widely used Python imaging libraries
Threat Intel
1
1 sources
Exploit
POC
Public exploit code exists
Data Quality
8 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA Vendor GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC Yes
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision
Out-of-Cycle
Exploitation
Poc
System Exposure· derived
Open
Automatable
Yes
Human Impact
High
Technical Impact
Partial

Priority Score

58
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +38
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

More in Pillow

View all
CVE-2022-30595 CRITICAL POC
9.8 May 25

libImaging/TgaRleDecode.c in Pillow 9.1.0 has a heap buffer overflow in the processing of invalid TGA image files. Rated

CVE-2026-59204 HIGH POC
8.7 Jul 14

Denial of service in Python Pillow (versions 8.2.0 through 12.2.0) allows remote attackers to exhaust memory during JPEG

CVE-2026-54058 HIGH POC
8.3 Jul 14

Out-of-bounds memory disclosure in Python Pillow before 12.3.0 lets an attacker who supplies a crafted McIdas AREA image

CVE-2026-59197 HIGH POC
8.2 Jul 14

Heap out-of-bounds write in Python Pillow prior to 12.3.0 lets an attacker who controls the rank-filter size parameter c

CVE-2026-59205 HIGH POC
7.5 Jul 14

Denial-of-service and controlled heap corruption in Python's Pillow imaging library (all versions prior to 12.3.0) occur

CVE-2026-59203 HIGH POC
7.5 Jul 14

Denial of service in Python Pillow 12.0.0 through 12.2.0 lets a remote attacker hang an application by supplying a craft

CVE-2026-59199 HIGH POC
7.5 Jul 14

Denial of service (and potential memory corruption) in Python Pillow before 12.3.0 arises when public image coordinate A

CVE-2026-55379 HIGH POC
7.5 Jul 06

Uncontrolled memory allocation in Python Pillow before 12.3.0 lets a crafted BDF font file exhaust available memory and

CVE-2026-59200 HIGH POC
7.5 Jul 14

Uncontrolled memory consumption in Python Pillow (PIL) versions 5.1.0 through 12.2.x allows a remote attacker to cause d

CVE-2026-55380 HIGH POC
7.5 Jul 06

Denial-of-service via memory exhaustion in Python Pillow before 12.3.0 allows a crafted GD-format (.gd) image to trigger

CVE-2026-54060 HIGH POC
7.5 Jul 06

Uncontrolled memory allocation in Python Pillow before 12.3.0 allows a maliciously crafted font file to trigger excessiv

CVE-2026-59198 HIGH POC
7.5 Jul 14

Out-of-bounds heap read in Python Pillow's TGA RLE encoder (versions 5.2.0 through 12.2.x) lets adjacent process heap by

Vendor StatusVendor

SUSE

Severity: Important
Product Status
SUSE Liberty Linux 8 Fixed
SUSE Linux Enterprise Module for Package Hub 15 SP7 Fixed
SUSE Linux Enterprise Server 16.0 SUSE Linux Enterprise Server for SAP applications 16.0 Fixed
openSUSE Leap 16.0 Fixed
openSUSE Tumbleweed Fixed

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy