Advisory

PYSEC-2026-4207

Details, part 2 of 2. The advisory

Details

Both conversions report success. Only the existing path is opened. Nothing in the conversion
result distinguishes the two cases, so the difference is usable as a silent file-existence oracle
against arbitrary paths.

Impact

Confirmed by execution, default install, no options set:

  1. Arbitrary local file read. A converted document names an absolute path and Docling opens it. Observed for /etc/passwd and for paths with no extension.
  2. Silent file existence and readability oracle. Present and absent paths are distinguishable by side effect while conversion reports success either way.
  3. Full content disclosure. Where the target decodes as an image, its bytes are embedded in the DoclingDocument and appear base64-encoded in the HTML, Markdown and JSON exports, byte for byte.

The disclosure in (3) is bounded to files Pillow can decode, and I would rather state that plainly
than overstate the finding. On a document-conversion host that class is not marginal: page images
from other conversions, scanned documents, cached artifacts and screenshots are exactly what such
a service accumulates. The project README describes "local execution capabilities for sensitive
data and air-gapped environments", which is the deployment where host-side file disclosure carries
the most weight.

Not demonstrated, and stated as such. I have not tested this behind docling-serve. .odt is
an accepted input format there, json is an accepted output format, and the service defaults to
binding 0.0.0.0 with DOCLING_SERVE_API_KEY unset, so on the face of it the same defect is
reachable by an unauthenticated remote caller with no user interaction. I have not run it, so I am
raising it for you to check rather than presenting it as a result.

Sources & licences