CVE-2026-40047
Apache Camel: Camel-Docling: Insufficient validation of custom CLI arguments enables argument injection and path traversal in DoclingProducer
Also known as GHSA-rpv3-6645-2vqc
Mitigation
- Upgrade org.apache.camel:camel-docling to 4.18.3 or later.
Who should check
- Projects that depend on Maven package org.apache.camel:camel-docling (>= 4.15.0, < 4.18.3)
- Anyone running Apache Software Foundation Apache Camel >= 4.15.0, < 4.18.3
Vulnerability facts
- Affected
- org.apache.camel:camel-docling >= 4.15.0, < 4.18.3
- Fixed in
- 4.18.3
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Remote, no login needed
- CVSS
- 9.1 (v3.1, CNA)CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:NOpen in CVSS calculator
Show all 8 CVSS metrics
- Attack vector: Network
- Attack complexity: Low
- Privileges required: None
- User interaction: None
- Scope: Unchanged
- Confidentiality impact: High
- Integrity impact: High
- Availability impact: None
- EPSS
- 2.43% chance of exploitation in 30 days (percentile 85, 2026-11-26)
- CWE
- CWE-88
- Modified
Description
Improper Neutralization of Argument Delimiters in a Command ('Argument Injection') vulnerability in Apache Camel Docling component. The camel-docling component invokes the external `docling` command-line tool by assembling an argument list in DoclingProducer and executing it through java.lang.ProcessBuilder. Custom CLI arguments supplied through the `CamelDoclingCustomArguments` exchange header (a List<String>) were appended to that argument list with insufficient validation: the original implementation relied on a denylist of disallowed flags and only rejected path values that contained a literal `../` sequence. As a result, a Camel route that forwards externally-influenced data into the `CamelDoclingCustomArguments` header (or into the path-bearing headers used to build the invocation) could cause the producer to pass unrecognized or unintended `docling` CLI flags to the subprocess, and could supply path-like argument values that resolved outside the intended directory through traversal sequences not caught by the literal `../` check. Because Camel itself builds the `docling` invocation from these values, the component is responsible for constraining them, and the weak validation allowed CLI-argument injection and directory traversal in the arguments passed to the external tool. The invocation uses the list-based form of ProcessBuilder, so a shell does not interpret the argument values; OS command injection through shell metacharacters was not possible, and the metacharacter rejection added by the fix is defense-in-depth. This issue affects Apache Camel: from 4.15.0 before 4.18.3. Users are recommended to upgrade to a release that contains the CAMEL-23212 fix. On the mainline the fix is included from Apache Camel 4.19.0 (and later releases such as 4.20.0). For users on the 4.18.x LTS releases stream, upgrade to 4.18.3. The fix replaces the denylist with a strict allowlist of recognized `docling` CLI flags (rejecting any unrecognized flag, and rejecting producer-managed flags such as the output-directory flags), defensively rejects shell metacharacters in argument values, and normalizes path-like values with Path.normalize() before validating them so that traversal sequences which bypass a literal `../` check are detected. As defence in depth, route authors should avoid mapping untrusted message content into the `CamelDoclingCustomArguments` header and the path-bearing headers, and should strip Camel-internal headers from messages that arrive from untrusted producers.
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| Maven org.apache.camel:camel-docling | >= 4.15.0, < 4.18.3 | 4.18.3 | osv |
| Apache Software Foundation Apache Camel | >= 4.15.0, < 4.18.3 | — | cvelist |
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2026-40047. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2026-40047.md Affected: org.apache.camel:camel-docling >= 4.15.0, < 4.18.3 Fixed in: 4.18.3 Steps: 1. Search this machine and project for org.apache.camel:camel-docling (Maven), Apache Software Foundation Apache Camel: dependency manifests and lockfiles, installed packages, container images and running services. 2. For each match, note the installed version and whether it is inside the affected range. 3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
References
Vendor advisories
Patches
FAQ
Is CVE-2026-40047 being exploited?
There is no confirmed exploitation: CVE-2026-40047 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 2.43% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2026-40047?
Critical: CVSS 9.1 (v3.1, scored by CNA). Remote, no login needed.
Which versions are affected by CVE-2026-40047?
org.apache.camel:camel-docling >= 4.15.0, < 4.18.3.
Is there a fix for CVE-2026-40047?
Yes. Fixed in 4.18.3. Upgrade org.apache.camel:camel-docling to 4.18.3 or later.
How do I check if I'm affected by CVE-2026-40047?
Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.