CVE-2026-110480: Apache Camel: Camel-SSH Host Key Verification Bypass via Substring Matching of known_hosts Entries
Incorrect Comparison and Authentication Bypass by Spoofing vulnerability in Apache Camel SSH component.
This issue affects Apache Camel: from 2.20.0 before 4.18.6, from 4.19.0 before 4.22.3, from 4.23.0 before 4.24.0.
In Apache Camel's camel-ssh component, the ResourceBasedSSHKeyVerifier used when a knownHostsResource is configured selected the server's trusted key by matching the connecting host against knownhosts entries with substring comparison and first-match-wins, instead of OpenSSH host-pattern semantics applied to the configured connection host. As a result the public key listed for a different but textually overlapping entry could be accepted when validating the server the client connects to, so host-key verification could confirm the wrong server's identity even with strict checking (failOnUnknownHost=true) enabled. This is fixed in 4.18.6, 4.22.3 and 4.24.0, which match the configured host with OpenSSH-compatible patterns (globbing, negation, hashed and revoked entries, all lines considered) and fail closed on an unreadable resource or entry.
Upgrade to Apache Camel 4.24.0, which fixes the issue. Users on the 4.22.x LTS release stream should upgrade to 4.22.3. Users on the 4.18.x LTS release stream should upgrade to 4.18.6.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 4.18.6 - Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 4.22.3 - Upgrade
Upgrade to a fixed release to a version that resolves this vulnerability.
Fixed in 4.24.0
Event History
Frequently Asked Questions
Which deployments are exposed?
Deployments using Apache Camel's camel-ssh component with a knownHostsResource configured are affected in the listed vulnerable release ranges. The issue concerns the ResourceBasedSSHKeyVerifier used for that configuration.
Does enabling strict unknown-host checking prevent this issue?
No. The vulnerability can cause verification of the wrong server identity even when failOnUnknownHost=true is enabled, because a different known_hosts entry with a textually overlapping host can be selected.
What must an attacker be able to do to exploit this?
The attacker must be able to present a server key that is trusted under a different, textually overlapping known_hosts entry. The vulnerable verifier can select that entry through substring matching and accept the wrong server identity.
How can I determine whether an application needs remediation?
Check whether the application uses camel-ssh with knownHostsResource and is running Apache Camel from 2.20.0 before 4.18.6, 4.19.0 before 4.22.3, or 4.23.0 before 4.24.0. Review known_hosts entries for host names that overlap textually, as these can trigger incorrect key selection.
What is the recommended remediation?
Upgrade to Apache Camel 4.24.0. For the 4.22.x LTS release stream, upgrade to 4.22.3; the fixed releases use OpenSSH-compatible host-pattern matching and fail closed when the resource or an entry cannot be read.