Skip to main content
← All vulnerabilities
CVE-2026-42589GHSA-RQGH-GXV4-6657GO-2026-5636

Gotenberg: Unauthenticated RCE via ExifTool Metadata Key Injection

Published
Last modified
published
Not listed in CISA KEV
Fix
Fixed in 8.31.0
3 proofs of concept on GitHub, 1 Nuclei template
  • Exploitation: poc
  • Automatable: yes
  • Technical impact: total

Summary

Gotenberg is a Docker-powered stateless API for PDF files. Prior to 8.31.0, Gotenberg's /forms/pdfengines/metadata/write HTTP endpoint accepts a JSON metadata object and passes its keys directly to ExifTool via the go-exiftool library. No validation is performed on key characters. A \n embedded in a JSON key splits the ExifTool stdin stream into a new argument line, allowing an attacker to inject arbitrary ExifTool flags — including -if, which evaluates Perl expressions. This achieves unauthenticated OS command execution in a single HTTP request. The response is HTTP 200 with a valid PDF, making the attack transparent to basic monitoring. This vulnerability is fixed in 8.31.0.

Timeline

  1. CVE published
  2. CISA SSVC assessment

    Exploitation: poc · Automatable: yes · Technical impact: total

  3. Record last updated

Affected versions

  • gotenberg gotenberg

    fixed in 8.31.0

  • github.com/gotenberg/gotenberg/v8Go

    8.29.1

  • github.com/gotenberg/gotenberg/v7Go

    All versions

  • github.com/gotenberg/gotenberg/v8Go

    All versions

References 5

GitHub · gotenberg/gotenberg

GitHub · projectdiscovery/nuclei-templates

GitHub · HackfutSecRoot/-GOTENBERG-RCE-CHAIN

GitHub · codeb0ssx/CVE-2026-42589xCVE-2026-40281-PoC

GitHub · fineman999/POC_CVE-2026-42589