Inefficient Algorithmic Complexity Affecting pillow package, versions [9.2.0,12.3.0)


Severity

Recommended
0.0
medium
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.37% (30th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-PYTHON-PILLOW-21277792
  • published20 Oct 2026
  • disclosed19 Oct 2026
  • creditSyed Mohammad Ibrahim

Introduced: 19 Oct 2026

NewCVE-2026-112891  (opens in a new tab)
CWE-407  (opens in a new tab)

How to fix?

Upgrade pillow to version 12.3.0 or higher.

Overview

Affected versions of this package are vulnerable to Inefficient Algorithmic Complexity via repeated string concatenation in the _seek function of src/PIL/GifImagePlugin.py when parsing GIF comment extension blocks. An attacker can supply a GIF file containing many comment blocks, causing quadratic memory growth through repeated bytes concatenation on each block read, which crashes the process.

CVSS Base Scores

version 4.0
version 3.1