# CVE-2026-112900: Pillow: Argument Injection in Ghostscript call, potentially leading into RCE

> Attackers can achieve remote code execution by injecting Ghostscript arguments via malicious EPS filenames in Pillow.

- **Severity:** Critical 9.2 (`CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 19 Oct 2026
- **Updated:** 20 Oct 2026
- **Also known as:** BIT-pillow-2026-112900, DEBIAN-CVE-2026-112900, ECHO-5292-da37-bea6, GHSA-w889-685w-c8fh, ROOT-APP-PYPI-CVE-2026-112900, UBUNTU-CVE-2026-112900

## What is CVE-2026-112900?

CVE-2026-112900 is a critical command injection vulnerability in Python Pillow, published on 19 Oct 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

Pillow is a Python imaging library. From 2.6.0 until 13.0.0, Pillow is vulnerable to argument injection when invoking Ghostscript for EPS input. EpsImagePlugin.Ghostscript passes a caller-controlled input filename after -f without converting it to a safe absolute path, so a name beginning with a hyphen can be interpreted as a Ghostscript option. An attacker who controls the filename can inject Ghostscript arguments. Arbitrary command execution specifically requires a leading @ argument-file filename and control of the referenced text file containing additional Ghostscript arguments; the reported chain reproduces with the default -dSAFER invocation. This issue is fixed in version 13.0.0.

Weakness: CWE-88 (Improper Neutralization of Argument Delimiters in a Command), CWE-78 (Improper Neutralization of Special Elements used in an OS Command)

## Which versions are affected by CVE-2026-112900?

3 open source packages ship an affected version, including pillow and Pillow. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `pillow` | Bitnami | From 2.6.0 | 13.0.0 |
| `pillow` | PyPI | From 2.6.0 | 13.0.0 |
| `Pillow` | PyPI | From 2.6.0 | 13.0.0 |

Products: Python Pillow.

## How do I fix CVE-2026-112900?

Upgrade pillow to 13.0.0 or later.

## Is CVE-2026-112900 being exploited?

There is no known exploitation of CVE-2026-112900 in the wild and no public exploit code.

Public exploit code:

- A complete guide and workflow for integrating Agile sprints with DevOps CI/CD pipelines. (github_poc): https://github.com/techupdate24/python-pillow-rce-cve-2026-112900
- https://github.com/moprius/CVE-2026-112900-Pillow-PoC (github_poc): https://github.com/moprius/CVE-2026-112900-Pillow-PoC
- Proof of Concept (PoC) demonstrating Argument Injection in Pillow's Ghostscript call (Pillow < 13.0.0) potentially leading to arbitrary command execution (RCE). (github_poc): https://github.com/kavin-jindal/CVE-2026-112900-PoC

## Other vulnerabilities in Python Pillow

- [CVE-2014-3007](https://insights.sbomify.com/CVE-2014-3007/): Pillow command injection (critical 10.0)
- [CVE-2026-96639](https://insights.sbomify.com/CVE-2026-96639/): Pillow multi-frame loaders can reuse stale native image storage after mode transitions (critical 9.8)
- [CVE-2022-30595](https://insights.sbomify.com/CVE-2022-30595/): Buffer over-flow in Pillow (critical 9.8)
- [CVE-2021-25289](https://insights.sbomify.com/CVE-2021-25289/): Out of bounds write in Pillow (critical 9.8)
- [CVE-2016-4009](https://insights.sbomify.com/CVE-2016-4009/): Pillow Integer overflow in ImagingResampleHorizontal (critical 9.8)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2026-112900 and fix it if it is affected.

What it is: CVE-2026-112900 is a critical command injection vulnerability in Python Pillow, published on 19 Oct 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: There is no known exploitation of CVE-2026-112900 in the wild and no public exploit code.

Affected packages and fixed versions:
- pillow (Bitnami): affected from 2.6.0; fixed in 13.0.0
- pillow (PyPI): affected from 2.6.0; fixed in 13.0.0
- Pillow (PyPI): affected from 2.6.0; fixed in 13.0.0

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2026-112900/ (Markdown: https://insights.sbomify.com/CVE-2026-112900/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2026-112900
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2026-112900
- OSV: https://osv.dev/vulnerability/CVE-2026-112900

---
From sbomify Insights: https://insights.sbomify.com/CVE-2026-112900/
Summaries are generated and may contain mistakes; the official description above is the record.
