Advisory

PYSEC-2026-2257

Also known as: BIT-pillow-2026-55798, CVE-2026-55798, GHSA-4x4j-2g7c-83w6

Summary

The record has no summary.

Details

Pillow is a Python imaging library. Prior to 12.3.0, WindowsViewer.get_command() constructed a cmd.exe shell command by directly embedding a file path into an f-string without escaping and passed the result to subprocess.Popen(..., shell=True), allowing shell metacharacters in the file path to inject arbitrary cmd.exe commands. This issue is fixed in version 12.3.0.

Severity

Medium Basis: CVSS v3 score 4.5, vector CVSS:3.1/AV:L/AC:H/PR:N/UI:R/S:U/C:L/I:L/A:L

Dates

Published
2026-07-06 19:17 UTC
Modified
2026-07-13 07:26 UTC

Affected packages and fixes

pillow

PyPI · All systems

Affected

  • introduced 0, fixed 12.3.0 (ecosystem)

Fixed versions

12.3.0

Fix

  • Fixed version 12.3.0
    pip install --upgrade pillow==12.3.0

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: PyPA Advisory Database · CC BY 4.0

Sources & licences