# CVE-2026-78162: Apache Camel: Camel-Hazelcast Managed Instances Missing Java Deserialization Filter (Incomplete Fix for CVE-2026-43865)

The Markdown version of <https://upatch.dev/cve/CVE-2026-78162>. Last updated 25 Nov 2026.

## At a glance

CVE-2026-78162 is rated Critical 10.0 (CVSS 4.0, CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X). It affects Apache Camel (Apache Software Foundation) and was published on 19 Oct 2026. It is not in CISA's Known Exploited Vulnerabilities catalog. Its EPSS score is 1.1%: the estimated chance it is exploited in the next 30 days, as of 24 Nov 2026. The upatch `cve-2026-78162-exec-block` mitigates it, and is vetted (merged into the registry).

A upatch is a signed BPF program that shirudo loads into a running Linux kernel to block the code path this CVE's exploit takes. It holds the line until the fix ships; it does not replace patching.

## The vulnerability

CVE-2026-78162, "Camel-Hazelcast: Incomplete fix for CVE-2026-43865 leaves managed instances without a Java deserialization filter, enabling remote code execution", was published on 19 October 2026. The fix for CVE-2026-43865 introduced `HazelcastSerializationFilterHelper.applyDefault(Config)` to attach a default `JavaSerializationFilterConfig` to Hazelcast instances created by `camel-hazelcast`, but missed two configuration paths: `ReplicatedHazelcastAggregationRepository.doStart()`, which overrides `HazelcastAggregationRepository.doStart()` without calling `super.doStart()` (CAMEL-24413), and `HazelcastDefaultComponent.getOrCreateHzClientInstance()`, which builds an unfiltered `ClientConfig` via `XmlClientConfigBuilder` when `hazelcastMode=client` is used without an explicit `ClientConfig` or `hazelcastConfigUri` (CAMEL-24420). An attacker who can publish to the Hazelcast cluster can send a crafted serialized Java object that Hazelcast deserializes before Camel processes the exchange, leading to remote code execution.

### Official description

Deserialization of Untrusted Data vulnerability in Apache Camel.

This issue affects Apache Camel: from 4.0.0 before 4.18.5, from 4.19.0 before 4.22.1.

The camel-hazelcast component applies a default Hazelcast JavaSerializationFilterConfig to the instances it creates from its own configuration, a protection introduced by CVE-2026-43865. That change did not reach two of the configuration paths Camel builds itself, so those paths continued to create Hazelcast instances whose Java deserialization is unrestricted. ReplicatedHazelcastAggregationRepository extends HazelcastAggregationRepository but overrides doStart() without calling super.doStart(), keeping its own copy of the bootstrap block, and therefore never received the filter: a route using it without supplying a hazelcastInstance starts a Hazelcast member that deserializes values read from the backing ReplicatedMap with no class restriction. HazelcastDefaultComponent#getOrCreateHzClientInstance() builds its own ClientConfig when hazelcastMode=client is selected and neither a referenced ClientConfig nor hazelcastConfigUri is supplied, and likewise applied no filter, so client-mode endpoints behaved differently from node-mode endpoints for an otherwise identical configuration. In both cases an attacker able to publish into the Hazelcast cluster that the affected instance is attached to can cause a serialized Java object of their choosing to be deserialized inside Hazelcast's own serialization layer, before Camel processes the exchange, resulting in remote code execution. Hazelcast clusters have neither authentication nor TLS enabled by default. Selecting client mode is a topology choice rather than a security option, so neither path required the deployment to opt in to unsafe behaviour.

Users are recommended to upgrade to version 4.23.0, which fixes the issue. If users are on the 4.22.x releases stream, then they are suggested to upgrade to 4.22.1. If users are on the 4.18.x releases stream, then they are suggested to upgrade to 4.18.5. The 4.14.x releases stream and earlier reached end of life before this issue was resolved and will not receive a fix, so deployments on those lines must move to a supported release. For deployments that cannot upgrade immediately, supply an explicit Hazelcast configuration carrying a JavaSerializationFilterConfig, or inject a pre-built HazelcastInstance, since a user-supplied configuration is never overwritten by Camel. Alternatively set the JVM-wide filter -Djdk.serialFilter=!java.net.;java.;javax.;org.apache.camel.;!\* and enable Hazelcast cluster authentication and TLS to restrict who can reach the cluster.

## What the upatch does

A BPF LSM program attached to `lsm/bprm_check_security` inspects the current task and its `real_parent`. When either task's executable (`mm->exe_file`) is named `java` and the first 256 bytes of its user command line (`mm->arg_start` to `mm->arg_end`) contain `camel-hazelcast`, the hook increments key 0 of the `refused` per-CPU array map and returns `-EPERM`. Checking both `current` and `real_parent` covers both direct `execve()` after `fork()` and the OpenJDK `jspawnhelper` helper path. Any refusal returned by an earlier BPF LSM program on the same hook is preserved.

The policy: [`cve-2026-78162-exec-block.bpf.c`](https://github.com/copper-helm/upatch-registry/tree/main/upatches/cve-2026-78162), 99 lines of BPF C attached at `lsm/bprm_check_security`, licensed GPL-2.0 OR BSD-2-Clause.

## Side effects

- A `java` process whose command-line arguments include `camel-hazelcast` inside the first 256 bytes cannot execute external programs (`Runtime.exec()`, `ProcessBuilder`).
- Normal in-JVM Camel routing, aggregation in `ReplicatedHazelcastAggregationRepository`, and Hazelcast cluster and client operations continue unaffected.
- Other processes on the machine, including other `java` processes that do not carry `camel-hazelcast` in their initial command-line arguments, are unaffected.
- Not covered: a JVM whose classpath uses wildcard expansion or an argument file (`@argfile`) so `camel-hazelcast` does not appear in the first 256 bytes of `mm->arg_start`, or in-memory post-deserialization effects that do not execute a new program.

## Preemption model and cost

The program is written for preemptible RCU (`PREEMPT_DYNAMIC`, `PREEMPT_LAZY` and `PREEMPT_RT` included). Refusals are counted in a per-CPU array map using an atomic fetch-and-add (`__sync_fetch_and_add`), which is safe when two runs interleave on the same CPU. The hook runs only on `execve()`, never on I/O or network paths, and returns immediately after checking the executable dentry name (`d_name.len == 4` and `"java"`) for non-Java processes.

## Affected versions

Apache Camel `camel-hazelcast`:

| Branch   | Affected         | Fixed in |
| -------- | ---------------- | -------- |
| 4.18.x   | 4.0.0 to 4.18.4  | 4.18.5   |
| 4.22.x   | 4.19.0 to 4.22.0 | 4.22.1   |
| mainline | 4.19.0 to 4.22.0 | 4.23.0   |

Kernels: any Linux kernel supported by shirudo with BTF and BPF LSM enabled.

## How it was tested

On Apache Camel 4.22.0 with camel-hazelcast and ReplicatedHazelcastAggregationRepository, the loaded upatch refused subprocess execution from the vulnerable JVM while normal Camel and Hazelcast operations continued.

- **Tested:** 25 Nov 2026
- **Target:** Apache Camel camel-hazelcast 4.22.0 with Hazelcast 5.4.0 (ReplicatedHazelcastAggregationRepository default Config without JavaSerializationFilterConfig), loopback only
- **Kernel:** 7.4-shirudo-ci-20261123
- **Architecture:** x86_64
- **Distribution:** Ubuntu 26.04

### Results

| State           | Subprocess execution from camel-hazelcast JVM blocked | Unfiltered ReplicatedHazelcastAggregationRepository active |
| --------------- | ----------------------------------------------------- | ---------------------------------------------------------- |
| Before loading  | no (reached)                                          | yes                                                        |
| Upatch loaded   | yes (blocked)                                         | yes                                                        |
| After unloading | no (reached)                                          | yes                                                        |

## How to apply

Build the upatch from source, sign it with your own shirudo key, and publish it to your own OCI registry. Machines that follow your upatch tree load it within about a minute.

Build and sign:

```sh
git clone https://github.com/copper-helm/upatch-registry
cd upatch-registry
tools/build <shirudo-checkout> <keys-dir> 1.0.0 upatches/cve-2026-78162
```

Publish and roll out:

```sh
shirudo bpm push build/packages/cve-2026-78162-1.0.0.bee oci://<registry>/<namespace>/cve-2026-78162 --keys-dir <keys-dir>
shirudo bpm tree append build/packages/cve-2026-78162-1.0.0.bee oci://<registry>/<namespace>/<tree> --tree-id <tree-id> --keys-dir <keys-dir>
```

## Review

- Contributors: romanlab.
- Reviewers: none recorded yet.

## Sources and links

- [Apache Camel Security Advisory CVE-2026-78162](https://camel.apache.org/security/CVE-2026-78162.html)
- [Apache Camel Security Advisory CVE-2026-43865](https://camel.apache.org/security/CVE-2026-43865.html)
- [CAMEL-24413 JIRA issue](https://issues.apache.org/jira/browse/CAMEL-24413)
- [CAMEL-24420 JIRA issue](https://issues.apache.org/jira/browse/CAMEL-24420)
- [Fix PR #25566 (commit 27836f4c17ed8cf33f1ef4dff9daed903b1b8907)](https://github.com/apache/camel/pull/25566)
- [Fix PR #25595 (commit 07318cfe7e07379a6155117d9c2cf27e99af4687)](https://github.com/apache/camel/pull/25595)
- [4.22.x backport PR #25599 (commit 02a864ba28f80bf8076f00aa2094c46377a74f43)](https://github.com/apache/camel/pull/25599)
- [4.18.x backport PR #25600 (commit aea69111dc3ff1f8a32271fc95632aee32eb3f37)](https://github.com/apache/camel/pull/25600)

### Links

- [CVE-2026-78162 on upatch.dev](https://upatch.dev/cve/CVE-2026-78162) (this page, as HTML)
- [NVD](https://nvd.nist.gov/vuln/detail/CVE-2026-78162)
- [CVE.org](https://www.cve.org/CVERecord?id=CVE-2026-78162)
- [Vendor advisory](https://camel.apache.org/security/CVE-2026-43865.html)
- [CWE-502](https://cwe.mitre.org/data/definitions/502.html)
- Upatch source: [upatches/cve-2026-78162](https://github.com/copper-helm/upatch-registry/tree/main/upatches/cve-2026-78162)

### More references from NVD (8)

- [camel.apache.org](https://camel.apache.org/security/CVE-2026-43865.html) (Mitigation, Not Applicable, Patch, Vendor Advisory)
- [camel.apache.org](https://camel.apache.org/security/CVE-2026-78162.html) (Mitigation, Patch, Vendor Advisory)
- [github.com](https://github.com/apache/camel/pull/25566) (Issue Tracking, Patch)
- [github.com](https://github.com/apache/camel/pull/25595) (Issue Tracking, Patch)
- [github.com](https://github.com/apache/camel/pull/25599) (Issue Tracking, Patch)
- [github.com](https://github.com/apache/camel/pull/25600) (Issue Tracking, Patch)
- [issues.apache.org](https://issues.apache.org/jira/browse/CAMEL-24413) (Issue Tracking, Patch, Vendor Advisory)
- [issues.apache.org](https://issues.apache.org/jira/browse/CAMEL-24420) (Issue Tracking, Patch)
