CVE-2023-38745 Path traversal in n/a

Medium 6.3 Published Updated

Attackers can overwrite arbitrary files via crafted image elements in Pandoc when using specific output options, potentially leading to code execution.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Local or same network only
Victim action needed
A user has to click or open something
Fix
Available

What is CVE-2023-38745?

CVE-2023-38745 is a medium-severity path traversal vulnerability in Debian Debian Linux, published on 25 Jul 2023. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.

Official description

Pandoc before 3.1.6 allows arbitrary file write: this 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. This allows an attacker to create or overwrite arbitrary files, depending on the privileges of the process running Pandoc. It only affects systems that pass untrusted user input to Pandoc and allow Pandoc to be used to produce a PDF or with the --extract-media option. NOTE: this issue exists because of an incomplete fix for CVE-2023-35936 (failure to properly account for double encoded path names).

Which versions are affected by CVE-2023-38745?

It affects 2 products.

Products include Debian Debian Linux, Pandoc Pandoc.

How do I fix CVE-2023-38745?

Upgrade to a fixed version.

Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.

Is CVE-2023-38745 being exploited?

There is no known exploitation of CVE-2023-38745 in the wild and no public exploit code.

All Debian Debian Linux vulnerabilities

Sources

Also known as GHSA-9hpj-m9v9-5wvw, JLSEC-2026-500, UBUNTU-CVE-2023-38745, openSUSE-SU-2024:13246-1.

Is CVE-2023-38745 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free