A vulnerability tracked as CVE-2026-125396 has been found in Ghostscript, the widely used open-source software for rendering PDF and PostScript files. It allows an attacker to bypass the program's "-dSAFER" safe mode and execute arbitrary code. VulnCheck, which assigned the CVE, published the record on November 10, 2026 (JST). On November 21, the finders, Paulos Yibelo and the security company pwn.ai, released a technical write-up showing the attack working through ordinary web apps that accept file uploads. Developer Artifex Software had already fixed the issue in Ghostscript 10.08.0, released on September 8.

Every Version Before 10.08.0 Is Affected

According to the CVE record, all Ghostscript versions before 10.08.0 are affected. The root cause is the ".putgstringcopy" procedure in the font-handling file "gs_fonts.ps," which called the privileged internal operator ".forceput" without checking the types of its operands. A crafted PostScript or PDF file can trigger a type error, recover ".forceput" through a custom error handler, and cause a use-after-free across save and restore operations, leading to arbitrary code execution.

The flaw is rated 8.5 under CVSS v4.0 and 7.8 under CVSS v3.1, both in the "High" range. The attack vector is classified as local, and exploitation requires some user involvement, such as opening or processing a file. Ken Sharp of Artifex developed the fix, and a change that validates the operands of ".putgstringcopy" is now in the GhostPDL repository.

ItemDetails
CVE IDCVE-2026-125396
AffectedGhostscript before 10.08.0
Fixed inGhostscript 10.08.0 (released September 8, 2026)
SeverityCVSS v4.0: 8.5 / CVSS v3.1: 7.8
Credited toPaulos Yibelo, pwn.ai

Image Uploads Can Reach Ghostscript

The "local" label does not mean online services are safe. Ghostscript is often used not on its own but as a back end that image-processing libraries call when they need to handle PDF or PostScript content.

According to pwn.ai's write-up, even a file named with a ".png" or ".jpg" extension can be passed to Ghostscript by an image library if its contents are actually PostScript. The company says it was able to run commands on servers by targeting systems that generate thumbnails from uploaded files. The paths it demonstrated include WordPress, the Roundcube webmail client, the MediaWiki wiki software, and shared printers (CUPS) on Debian 13, as well as routes through the Python imaging library Pillow and others.

The company also says the vulnerability was found through a collaboration between an AI model and Yibelo. pwn.ai is a company that offers automated, AI-driven penetration testing.

Update, and Check for Bundled Copies

The basic fix is to update Ghostscript to 10.08.0 or later, or to a patched package from a Linux distribution. As of this writing, the official Ghostscript website lists 10.08.0 as the latest release. pwn.ai's write-up says Debian and Ubuntu have shipped patched packages, while some distributions had not finished their updates as of November 12.

One point to watch: updating the operating system's packages may leave older Ghostscript copies untouched inside container images or bundled with applications. The company recommends checking which Ghostscript build the code that actually converts files is using. It also advises requiring authentication on shared print queues, checking a file's real type before generating thumbnails, and restricting the privileges of conversion processes.

Our Take

Ghostscript runs behind many web services and apps without users being aware of it. That means operators who don't remember ever installing it may be the slowest to respond. With the CVE and attack details published more than two months after the fix, attempts to target unpatched systems could follow.

On the other hand, the fixed release has been out since September, and Debian and Ubuntu are said to have patched. Still, old copies bundled in containers and apps are easy to overlook. Operators of services that accept file uploads would do well to map out their image-processing paths at least once.

Summary

A vulnerability in Ghostscript versions before 10.08.0 can lead to arbitrary code execution through crafted files, and its finders demonstrated attacks via image uploads. It affects operators of servers and apps that use Ghostscript or image-processing libraries that call it. Beyond updating to 10.08.0 or later, copies bundled in containers and applications should be checked as well.