CVE-2025-51591
LowCVSS 3.7Exploitation Probability (EPSS)
Low risk45th percentile - higher than 45% of all known CVEs
Summary
An SSRF vulnerability in JGM Pandoc v3.6.4 allows attackers to inject a crafted iframe, gaining access to and compromising the entire infrastructure. Pandoc's default behavior of fetching and parsing untrusted HTML can facilitate exploitation of this flaw.
Risk Assessment
The risk involves potential remote scanning and attacking of internal organizational resources, leading to data breaches, system compromise, and further escalation within the infrastructure.
Recommendation
Immediately update Pandoc to the latest version and use the '--sandbox' option or 'pandoc-server' to mitigate risks. Avoid using external PDF engines like wkhtmltopdf without proper security measures.
Other vulnerabilities in Pandoc
See all- CVE-2023-38745Medium
Pandoc versions before 3.1.6 allow arbitrary file write, which can be triggered by providing a crafted image element in the input when generating files via the --extract-media option or outputting to PDF format.
- CVE-2023-35936Medium
Pandoc, a Haskell library for converting markup formats, has an arbitrary file write vulnerability that can be triggered by a specially crafted image element in the input. This affects versions from 1.13 to 3.1.4 when generating files using the `--extract-media` option or outputting to PDF format.
Original NVD description (English source)
A Server-Side Request Forgery (SSRF) in JGM Pandoc v3.6.4 allows attackers to gain access to and compromise the whole infrastructure via injecting a crafted iframe. Note: Some users have stated that Pandoc by default can retrieve and parse untrusted HTML content which can enable SSRF vulnerabilities. Using the ‘--sandbox’ option or ‘pandoc-server’ can mitigate such vulnerabilities. Using pandoc with an external ‘--pdf-engine’ can also enable SSRF vulnerabilities, such as CVE-2022-35583 in wkhtmltopdf.
Vulnerability data from NVD (NIST) · CISA KEV · EPSS

