🛡️
CVE 📅 2026-10-27 · 08:54 AM IST ⏱ 6 min read

Critical Pillow Flaw Lets Crafted Filenames Inject Ghostscript Arguments; Version 13.0.0 Fixes It

By ITVedas Technical Leadership · Published 2026-10-27

CVE-2026-112900, rated 9.2 Critical, affects Pillow 2.6.0 up to 13.0.0 through its Ghostscript EPS handling. Upgrade to 13.0.0.

A critical flaw in Pillow, one of the most widely used image-processing libraries in Python, can let an attacker who controls a filename inject extra arguments into the Ghostscript program that Pillow uses to render EPS images. The Pillow project fixed the bug, tracked as CVE-2026-112900, in version 13.0.0, released on October 16, 2026. The CVE record followed on October 19 with a CVSS 4.0 score of 9.2. GitLab has since published a remediation guide. It says GitLab's own products are not affected, but that many customer Python projects likely are.

What happened

The sequence of events, according to GitLab's write-up and the CVE record, is short:

GitLab said its Security team found no evidence of impact on GitLab-managed infrastructure. Its products do not include Pillow, so GitLab.com, GitLab Self-Managed and GitLab Dedicated are not affected. The company's guide is aimed at security and platform teams that host Python projects on GitLab and need to find every affected codebase.

Who is affected

The vulnerable range is wide. According to the CVE description, every Pillow release from 2.6.0 up to, but not including, 13.0.0 is affected. That covers many years of releases. The CVE record lists 13.0.0 as the only fixed version, so there are no backported patches for older release branches. Every project still on an older line has to move to 13.0.0.

Many teams may not realise they use Pillow at all. GitLab points out that Pillow is often a transitive dependency, meaning a library pulled in by another library rather than chosen directly. Web frameworks, thumbnail generators and machine-learning toolkits commonly bring it in several layers down the dependency tree.

Pillow installed through a Linux distribution's package manager is a separate case, because distributions use their own version numbers. GitLab's snapshot from October 26 reported:

Not every Pillow user can actually be attacked this way. GitLab says a system is exposed only when all of the following are true:

Services that generate their own filenames, or that process images entirely in memory, are much less likely to be reachable.

How it works

EPS (Encapsulated PostScript) files are not simple pictures. They are small programs written in the PostScript language. Pillow cannot draw them by itself, so it hands the work to Ghostscript, an external interpreter, by launching it as a separate command.

The problem is in how Pillow builds that command. According to the CVE description, Pillow's EpsImagePlugin.Ghostscript placed the caller-supplied input filename on Ghostscript's command line without first turning it into a safe absolute path. Like many command-line tools, Ghostscript treats certain leading characters as special:

Pillow already runs Ghostscript with -dSAFER, a sandbox setting that limits what a PostScript program can do. GitLab notes that the advisory says this protection does not help here. The sandbox restricts the document being rendered, while this attack changes the command line used to launch Ghostscript in the first place. For the same reason, GitLab says framework updates and checks on image contents will not prevent the issue, because the dangerous input is the filename, not the file data.

How serious is it?

The CVE Numbering Authority rated the flaw 9.2 (Critical) on CVSS 4.0, and ITVedas's CVE database records the same score. The bug is not on CISA's Known Exploited Vulnerabilities list, and GitLab says no exploitation in the wild has been reported so far.

There are still reasons for urgency. GitLab reports that CISA's assessment marks the issue as automatable with "total technical impact." That means that where the conditions are met, attacks could be scripted at scale and the consequences could be severe.

The real-world risk depends heavily on how an application handles uploads. Argument injection needs only control of the filename. Full command execution additionally requires control over an @-referenced text file. GitLab's guide and the CVE data agree on these points, and we found no disagreements between the sources.

What to do now

For administrators and developers:

For everyday users:

What we still don't know

ITVedas analysis: The highest risk here is less the bug itself than how hard it is to see. Pillow is often buried several layers deep in dependency trees and container images, so teams that only check their direct dependencies may miss it. Organisations should take inventory first and patch quickly, and should remove Ghostscript from any image that does not need it.

📎 This article is AI-assisted commentary produced by ITVedas's automated news pipeline, based on reporting by about.gitlab.com. Full technical record: CVE-2026-112900. It is checked by an automated review step, not by a human editor. Read the original report for full details and verify critical facts before acting on them.

Want to understand the technology behind this story? ITVedas has beginner-friendly guides on every IT topic.

Explore IT Chapters →