Docling: Configured HTTP headers sent to every remote image host named by a document
docling-project docling · docling-project docling-slim
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| docling PyPI |
|
|
| docling-slim PyPI |
|
|
docling-project docling · docling-project docling-slim
| Product | Affected | Fixed in |
|---|---|---|
| docling PyPI |
|
|
| docling-slim PyPI |
|
|
Docling simplifies document processing by parsing diverse formats and providing integrations with the generative AI ecosystem. From 2.95.0 until 2.132.0, the HTML image resource loader in docling/backend/utils/image_resource_loader.py forwards headers configured through the HTMLBackendOptions.headers setting to every remote image URL named by an untrusted document when enable_remote_fetch=True and fetch_images=True. The loader does not restrict those credentials to the source document's origin, allowing requests that carry custom headers such as API keys and cookies to follow cross-origin redirects and expose the caller's configured credentials to a document author. The default configuration is not affected because remote fetching and configured headers are required. This issue is fixed in 2.132.0.
From the CVE record · GitHub_M
The HTML image resource loader in docling and docling-slim can send configured headers, including credentials, to remote image URLs in an untrusted document, including across origins. A document author could obtain those credentials when the document is processed with remote fetching, image fetching, and custom headers enabled. The default configuration is not affected.
Anyone running PyPI docling or docling-slim versions 2.95.0 through versions before 2.132.0 should check their configuration.