CVE-2026-55798Pillow: WindowsViewer.get_command() OS command injection via unescaped shell path
A medium-severity vulnerability reachable with local access, needing no privileges and user interaction. EPSS estimates a 0.2% chance of exploitation in the next 30 days. A fixed version is named.
- Exploited in the wild
- Not in KEV
- EPSS
- 0.2%
- percentile 4%
- Fix
- Named by a source
- CVE published 6 Jul 2026
Reference
None of the "Needs attention" rules apply right now.
EPSS 0.2% (+0) · Public exploit or proof of concept (+15) · No privileges required (+5)
Immediate actions
- pillow (PyPI): upgrade to 12.3.0 or later on your release line.
- Patch: https://github.com/python-pillow/Pillow/commit/8404ea5fe5df40fc34aa1e51403dd6fce0778b8a
- Patch: https://github.com/python-pillow/Pillow/commit/88194166691b7b603529b8b036ab3ab9cedd2de4
- Patch: https://github.com/python-pillow/Pillow/commit/b0e06caa64c1405aa3da0bb1d2bd9a77ca22de7f
- Advisory: https://github.com/python-pillow/Pillow/blob/main/docs/releasenotes/12.3.0.rst
- Advisory: https://nvd.nist.gov/vuln/detail/CVE-2026-55798
Who should check
pillow (PyPI) pkg:pypi/pillow
- Affected< 12.3.0Fixed in12.3.0OSV (PYSEC-2026-2257)
python pillow product:python/pillow
- Affected< 12.3.0Affected range ends before12.3.0as published by CPE data (via the NVD API)
python-pillow Pillow product:pythonpillow/pillow
- Affected< 12.3.0Affected range ends before12.3.0as published by CNA (CVE List)
Products (not packages) are shown as their sources publish them. We check no product version against these ranges; a fixed version is the one the source names. Ask the vendor's advisory.
Confirmed facts
- CVSS
- 4.5 MEDIUM (version 3.1)
- Score from
- CNA ([email protected])
- Attack vector
- local
- Attack complexity
- high
- Privileges required
- none
- User interaction
- required
- Weakness
- CWE-78
- Exploitation (CISA SSVC)
- poc
- Automatable (CISA SSVC)
- no
- Assigned by
- [email protected]
Unknowns
- We show one CVSS score. Other sources may score this CVE differently.
Advisory text
Quoted from the source advisory (untrusted)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.
Update history
- 6 Jul 2026Published
References
- advisoryhttps://github.com/python-pillow/Pillow/blob/main/docs/releasenotes/12.3.0.rst
- patchhttps://github.com/python-pillow/Pillow/commit/8404ea5fe5df40fc34aa1e51403dd6fce0778b8a
- patchhttps://github.com/python-pillow/Pillow/commit/88194166691b7b603529b8b036ab3ab9cedd2de4
- patchhttps://github.com/python-pillow/Pillow/commit/b0e06caa64c1405aa3da0bb1d2bd9a77ca22de7f
- exploithttps://github.com/python-pillow/Pillow/security/advisories/GHSA-4x4j-2g7c-83w6
- advisoryhttps://nvd.nist.gov/vuln/detail/CVE-2026-55798
- otherhttps://github.com/pypa/advisory-database/tree/main/vulns/pillow/PYSEC-2026-2257.yaml
- otherhttps://github.com/python-pillow/Pillow
Sources
- EPSS by FIRST.org, Free to use, attribution requested. Scores generated by Empirical Security.
- CVE-2026-55798 (CVE List (CNA and CISA ADP data, through the NVD API)), CVE terms of use. Copyright The MITRE Corporation. CVE is a registered trademark of The MITRE Corporation.
- NVD API 2.0 (NIST), the API we query, NVD API terms of use. This product uses the NVD API but is not endorsed or certified by the NVD.
- GHSA-4x4j-2g7c-83w6 (GitHub Advisory Database), CC BY 4.0.
- PYSEC-2026-2257 (PyPA Advisory Database), CC BY 4.0.
- OSV.dev, Per database.
This page is our own presentation: records are shortened, normalised and merged. Licences
Last checked: kev 18 min ago · osv 18 min ago · nvd 78 min ago · epss 17 min ago · JSON · ask via MCP: explain_vulnerability
Also known as BIT-pillow-2026-55798, GHSA-4x4j-2g7c-83w6, PYSEC-2026-2257