← Security advisories
Apache Camel security advisory

CVE-2026-85245

Camel-Thrift: cross-exchange data disclosure - unmarshalling deserialized into the shared defaultInstance rather than a copy, so fields set by one message remained visible to the next

Description

The Thrift data format unmarshalled incoming data into the shared defaultInstance of the target type rather than into a fresh copy, and returned that shared object as the exchange body. Because the instance is shared process-wide, state written while unmarshalling one message stayed on the object and was visible to every later message that used the same type. Fields absent from a later payload retained the previous message's values, so content belonging to one sender could be read while processing another sender's message, and concurrent exchanges could observe each other's partially written state. In a deployment that serves more than one tenant or user through the same route, that is disclosure of one party's data to another.

Mitigation

Upgrade to Apache Camel 4.23.0, which fixes the issue. Users on the 4.18.x LTS releases stream should upgrade to 4.18.5. Users on the 4.22.x LTS releases stream should upgrade to 4.22.1. Unmarshalling now deserializes into a copy, so each exchange gets its own instance and no state carries between messages. For deployments that cannot upgrade immediately, copy the unmarshalled body into a new instance immediately after the data format runs, and do not retain references to the returned object.

Credit

This issue was discovered by Claude Security Scan Tool

Notes

The JIRA ticket: https://issues.apache.org/jira/browse/CAMEL-24442 refers to the various commits that resolved the issue, and has more details.

The fix was merged on main in https://github.com/apache/camel/pull/25823 (commit c52d3cfa1c343a49261d77a5213dba92244a38f6), backported to camel-4.22.x in https://github.com/apache/camel/pull/25940 (commit 260989268cbc6d258b1fcba63770be8ebbec40cb) and to camel-4.18.x in https://github.com/apache/camel/pull/25942 (commit af1efbcccf5882b1ef0094db718972da3190e7e9).

The issue is classified as CWE-488 Exposure of Data Element to Wrong Session. The camel-4.14.x line reached end of life before this fix and does not receive it; deployments on 4.14.x should move to 4.18.5 or later.

References