Description
Pillow is a Python imaging library. Prior to 13.0.0, Pillow's XBM header parser is vulnerable to regular-expression denial of service. In XbmImageFile._open, when an application calls Image.open() on a small crafted XBM file, XbmImagePlugin applies a backtracking expression to the attacker-controlled header before image dimensions are accepted, stalling a worker for minutes and denying service. This issue is fixed in version 13.0.0.
Published: 2026-10-19
Score: 6.9 Medium
EPSS: < 1% Very Low
KEV: No
Impact: Denial of Service
Action: Immediate Patch
AI Analysis

Impact

Pillow is a popular Python imaging library that includes an XBM image file parser. A back‑tracking regular expression in XbmImageFile._open processes the XBM header before the image’s dimensions are validated. An attacker can supply a small, crafted XBM file that causes the expression to consume excessive CPU time, stalling Image.open() for minutes and denying service to the worker that performs the call. The flaw is mapped to CWE‑1333 and results in a denial of service condition for any process that opens the malicious file.

Affected Systems

This vulnerability affects any installation of the python‑pillow Pillow library with a version earlier than 13.0.0. All users who load unpatched code—regardless of the deployment environment—are susceptible if they accept or open XBM files. Upgrading to Pillow 13.0.0 or later removes the problematic regular expression and mitigates the issue.

Risk and Exploitability

The CVSS score of 6.9 indicates a moderate severity. EPSS data is unavailable, and the vulnerability is not listed in the CISA KEV catalog. Exploitation requires an application that calls Pillow’s Image.open() on an XBM file supplied by an attacker. The most likely vectors are services or scripts that process untrusted XBM input locally or over a network, though no confirmed remote code execution or privilege escalation has been reported. The primary risk is resource exhaustion leading to denial of service.

Generated by OpenCVE AI on October 20, 2026 at 07:14 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade Pillow to version 13.0.0 or later.
  • If an upgrade cannot be performed immediately, remove or bypass XbmImagePlugin by editing the Pillow import paths or by eliminating calls that import this plugin, and ensure that XBM files are rejected or validated before calling Image.open().
  • Implement monitoring or alerting on prolonged Image.open() calls to detect potential stalls, and consider throttling or queuing image processing tasks to mitigate impact.

Generated by OpenCVE AI on October 20, 2026 at 07:14 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Github GHSA Github GHSA GHSA-xgh8-jp6q-p5x8 Pillow: ReDoS in XbmImagePlugin: 512-byte file stalls Image.open() for minutes
History

Tue, 27 Oct 2026 15:00:00 +0000

Type Values Removed Values Added
First Time appeared Python
Python pillow
CPEs cpe:2.3:a:python:pillow:*:*:*:*:*:*:*:*
Vendors & Products Python
Python pillow
Metrics cvssV3_1

{'score': 5.3, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L'}

cvssV3_1

{'score': 7.5, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H'}


Tue, 20 Oct 2026 17:30:00 +0000

Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}


Tue, 20 Oct 2026 12:45:00 +0000

Type Values Removed Values Added
References
Metrics threat_severity

None

cvssV3_1

{'score': 5.3, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L'}

threat_severity

Moderate


Tue, 20 Oct 2026 00:00:00 +0000

Type Values Removed Values Added
First Time appeared Python-pillow
Python-pillow pillow
Vendors & Products Python-pillow
Python-pillow pillow

Mon, 19 Oct 2026 22:15:00 +0000

Type Values Removed Values Added
Description Pillow is a Python imaging library. Prior to 13.0.0, Pillow's XBM header parser is vulnerable to regular-expression denial of service. In XbmImageFile._open, when an application calls Image.open() on a small crafted XBM file, XbmImagePlugin applies a backtracking expression to the attacker-controlled header before image dimensions are accepted, stalling a worker for minutes and denying service. This issue is fixed in version 13.0.0.
Title Pillow: ReDoS in XbmImagePlugin: 512-byte file stalls Image.open() for minutes
Weaknesses CWE-1333
References
Metrics cvssV4_0

{'score': 6.9, 'vector': 'CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N'}


Subscriptions

Python Pillow
Python-pillow Pillow
cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-10-20T16:08:29.821Z

Reserved: 2026-10-19T20:16:09.857Z

Link: CVE-2026-112901

cve-icon Vulnrichment

Updated: 2026-10-20T15:19:11.783Z

cve-icon NVD

Status : Analyzed

Published: 2026-10-19T22:17:10.293

Modified: 2026-10-27T14:54:34.653

Link: CVE-2026-112901

cve-icon Redhat

Severity : Moderate

Publid Date: 2026-10-19T22:09:52Z

Links: CVE-2026-112901 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-10-20T07:15:11Z

Weaknesses
  • CWE-1333

    Inefficient Regular Expression Complexity