Skip to main content
← All vulnerabilities
CVE-2026-55798PYSEC-2026-2257BIT-PILLOW-2026-55798GHSA-4X4J-2G7C-83W6

Pillow: WindowsViewer.get_command() OS command injection via unescaped shell path

Published
Last modified
published
Not listed in CISA KEV
Fix
Fixed in 12.3.0
None on Exploit-DB, Metasploit or GitHub
  • Exploitation: poc
  • Automatable: no
  • Technical impact: partial

Summary

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.

Timeline

  1. CVE published
  2. CISA SSVC assessment

    Exploitation: poc · Automatable: no · Technical impact: partial

  3. Record last updated

Affected versions

  • python-pillow Pillow

    fixed in 12.3.0

  • pillowPyPI

    fixed in 12.3.0

References 5

GitHub · python-pillow/Pillow