Skip to content
KitploitKITPLOIT
HerramientasExploitsBlog
Log in
Enviar
HerramientasExploitsBlog
Enviar

¡Herramientas de Hacking, PenTest y Ciberseguridad para tu Arsenal de Seguridad!

Kitploit es un directorio de herramientas de hacking, ciberseguridad y pentesting. Descubre las últimas actualizaciones de proyectos para encontrar vulnerabilidades, analizar sistemas, automatizar pruebas y fortalecer tu seguridad.

FeedsContactoPrivacidad© 2026 Kitploit

Directorio de Herramientas

Categorías

Ver todas las categorías
Loading categories
CVE-2026-112900-Pillow-PoC — Non-destructive proof of concept for CVE-2026-112900, demonstrating Ghostscript argument injection in Pillow's EPS rendering path with isolated Docker/Podman vulnerable-vs-patched comparison. | Kitploit
Herramientas/GitHubGitHub/moprius/cve-2026-112900-pillow-poc
Container SecurityVulnerability AnalysisExploitationWeb Application ExploitationPapers & ResearchLearning & Education
GitHubmoprius/cve-2026-112900-pillow-poc

CVE-2026-112900-Pillow-PoC

Compartir

Non-destructive proof of concept for CVE-2026-112900, demonstrating Ghostscript argument injection in Pillow's EPS rendering path with isolated Docker/Podman vulnerable-vs-patched comparison.

Ver Repositorio
hace 28 díasAún no revisado
Contenido no disponible en el idioma solicitado. Mostrando versión en inglés.

CVE-2026-112900: Pillow / Ghostscript Argument Injection — Safe PoC

Unit tests Python License: MIT Demonstration

Language: English · Leia em Português (Brasil)

A reproducible, non-destructive proof of concept for the argument-injection vulnerability (CWE-88) in Pillow's EPS rendering path when invoking Ghostscript. The project compares a vulnerable Pillow release with the first fixed release, supplies an isolated Docker/Podman environment, and includes automated unit tests and technical documentation.

Important scope limitation: This PoC passes only Ghostscript's -h (help) option as a specially named EPS file. It demonstrates argument injection, not arbitrary command execution (RCE). It does not include an RCE payload, an @ argument-file payload, any network exploit, or code to attack a remote application. The upstream advisory discusses additional conditions under which RCE is possible.

At a glance

ItemDetails
CVECVE-2026-112900
GitHub Security AdvisoryGHSA-w889-685w-c8fh
Affected softwarePillow (Python Imaging Library fork)
Affected versions>= 2.6.0 and < 13.0.0
First fixed version13.0.0
Relevant functionPIL.EpsImagePlugin.Ghostscript()
WeaknessCWE-88 (argument injection); the advisory also describes a conditional CWE-78 chain
Safe demonstrationRelative EPS filename -h triggers Ghostscript help on affected versions
Default container imageUbuntu 24.04 + Ghostscript + selected Pillow version

Sources: Pillow's official security advisory and the GitHub Advisory Database.

Why this happens

Pillow supports reading EPS (Encapsulated PostScript) files using PIL.EpsImagePlugin. When an EPS image is rendered, Pillow calls Ghostscript to process the image.

In affected versions, the file name is passed to Ghostscript as an argument following -f, without first making the file path unambiguously a path. If the relative file name begins with -, Ghostscript may interpret it as an option instead of the intended EPS input filename.

This demo creates a valid EPS file literally named -h, opens it with Pillow using that relative name, and invokes load(). If Ghostscript prints its help text, that is observable evidence that the name was processed as a command-line option.

Application calls Image.open("-h") and image.load()
               |
               v
Pillow 12.3.0 forwards the relative filename to Ghostscript
               |
               v
Ghostscript parses "-h" as the help option
               |
               v
Result: VULNERABLE  (argument injection observed, NOT RCE)

The fixed version normalizes the relevant file path before passing it to Ghostscript. See technical analysis for the affected code path, prerequisites, and mitigation guidance.

Requirements

  • Preferred: Docker or Podman (Fedora users can use rootless Podman).
  • Internet connectivity during the image build only, to download the Ubuntu packages and the specified Pillow release.
  • A disposable environment under your control or with explicit authorization.
  • If running without a container: a compatible Python 3 environment, Ghostscript installed, and Pillow installed in a dedicated virtual environment, not the host's system Python.

This repository intentionally provides a build argument that installs Pillow 12.3.0, a known vulnerable version. Do not use the vulnerable image for production, public services, or processing untrusted files.

Quick start — Fedora with Podman

Run these commands from the repository root (the directory containing Dockerfile). First build the intentionally vulnerable image:

podman build -t pillow-ghsa:vulnerable \
  --build-arg PILLOW_VERSION=12.3.0 .

Run the safe demonstration with networking disabled, a read-only root filesystem, dropped capabilities, and a private writable temporary directory:

podman run --rm --network none \
  --read-only --cap-drop all \
  --security-opt no-new-privileges \
  --tmpfs /tmp:rw,nosuid,nodev,noexec,size=32m \
  pillow-ghsa:vulnerable

You should see Result: VULNERABLE when the help-option injection is reproduced.

Now build Pillow 13.0.0, the first fixed release:

podman build -t pillow-ghsa:patched \
  --build-arg PILLOW_VERSION=13.0.0 .

And run the same test under the same container restrictions:

podman run --rm --network none \
  --read-only --cap-drop all \
  --security-opt no-new-privileges \
  --tmpfs /tmp:rw,nosuid,nodev,noexec,size=32m \
  pillow-ghsa:patched

You should see Result: NOT_REPRODUCED if the EPS renders without Ghostscript treating -h as an option.

Why compare two versions? The version contrast makes the observation more meaningful: the same benign file, tool invocation, and runtime configuration are used, while the Pillow version changes. It still does not constitute a security audit of your host or web service.

Docker equivalent

Replace podman with docker in the four commands above. The syntax of the build arguments and most isolation flags is the same.

Verbose and machine-readable output

Pass the following flags after the image name:

podman run --rm --network none \
  --read-only --cap-drop all \
  --security-opt no-new-privileges \
  --tmpfs /tmp:rw,nosuid,nodev,noexec,size=32m \
  pillow-ghsa:vulnerable python /app/poc.py --verbose
podman run --rm --network none \
  --read-only --cap-drop all \
  --security-opt no-new-privileges \
  --tmpfs /tmp:rw,nosuid,nodev,noexec,size=32m \
  pillow-ghsa:vulnerable python /app/poc.py --json

--verbose displays a truncated copy of captured Ghostscript output. --json provides structured data, including the detection status, runtime versions, and observed subprocess output.

How to recognize a successful test

Expected example on a vulnerable Pillow version:

Pillow / Ghostscript argument-injection laboratory
Advisory: GHSA-w889-685w-c8fh | CVE: CVE-2026-112900
Pillow: 12.3.0
Ghostscript: 10.x.x
Payload: -h (Ghostscript help; harmless argument injection)
Result: VULNERABLE
Details: Ghostscript interpreted '-h' as its help option: argument injection was reproduced. This does NOT demonstrate RCE.

Expected example with the fixed Pillow version:

Pillow / Ghostscript argument-injection laboratory
Advisory: GHSA-w889-685w-c8fh | CVE: CVE-2026-112900
Pillow: 13.0.0
Ghostscript: 10.x.x
Payload: -h (Ghostscript help; harmless argument injection)
Result: NOT_REPRODUCED
Details: EPS loaded without triggering Ghostscript help. This is consistent with a patched implementation; it is not a complete security audit.

The Ghostscript version will depend on the image build and may differ from the examples.

Descargar herramienta

Más Populares

Ver todos →

Descubre las herramientas más usadas por nuestra comunidad.

  • 1

    OsintHunter

    letox4/osinthunter

    🎯 El kit de herramientas OSINT definitivo: grafo de investigación, puntuación de confianza, familias de alias, mapa, línea de tiempo e informes. 49 módulos, más de 400 sitios, sin necesidad de claves API.

    1.0k
  • 2

    ghostlock-app

    yukonga/ghostlock-app

    # Aplicación de Ejecución con un Solo Toque GhostLock (CVE-2026-43499)

    647
  • 3

    looking-glass

    anonghosty/looking-glass

    Plataforma CSIRT que ingiere informes de Shadowserver en MongoDB y los reproduce como mapas interactivos, análisis, hallazgos, avisos y paneles ejecutivos.

    421
  • 4

    jumpserver

    jumpserver/jumpserver

    JumpServer es una plataforma de gestión de accesos privilegiados (PAM) de código abierto que proporciona a los equipos de DevOps y TI acceso seguro y bajo demanda a endpoints SSH, RDP, Kubernetes, base de datos y RemoteApp a través de un navegador web.

    389
  • 5

    ARTEX

    baarai/artex

    Plataforma de pruebas de penetración autónoma multiagente basada en LLM con agentes planificadores/trabajadores, grafos de activos y de exploración, registro de tráfico MITM y reevaluación de vulnerabilidades.

    333
  • 6

    SafeLine

    chaitin/safeline

    Proxy inverso y WAF autoalojado que filtra tráfico HTTP malicioso, bloquea inyecciones SQL, XSS y ataques de bots, con limitación de velocidad y cifrado dinámico de HTML/JS.

    331

Explora todas las herramientas

Explora nuestra colección de herramientas

Ver todas las herramientas →