🔥 CVE-2026-71300 深度独立研究:源码审计 · 二次发现 · 利用方案
CVE-2026-71300 深度独立研究:源码审计 · 二次发现 · 利用方案
🔍 源码独立审计
对 (未定位到源码) 源码进行独立审计(置信度 60%)。
🧬 根因独立理解
<p><strong>摘要:</strong>CVE-2026-71300 是 Apache Camel Atmosphere Websocket 组件中的一个高危输入验证漏洞,CVSS 评分为 9.8,属于可远程未授权利用的关键缺陷。漏洞根因是 camel-atmosphere-websocket 生产者使用 <code>websocket.*</code> 形式的 Exchange 头控制 WebSocket 消息投递,而 Camel 的 HTTP HeaderFilterStrategy 只过滤 <code>Camel*</code> / <code>camel*</code> 前缀,导致外部攻击者可注入 <code>websocket.connectionKey.list</code>、<code>websocket.sendToAll</code> 等头,覆盖路由原本选择的投递目标。官方修复版本为 4.14.9、4.18.4 和 4.22.0。</p> <h2>📌 漏洞概述</h2> <p>CVE-2026-71300 是 Apache Camel Atmosphere Websocket 组件中的“输入验证不当”(Improper Input Validation,CWE-20)漏洞,攻击者无需身份认证即可远程触发,CVSS 评分 9.8,严重性为 Critical。</p> <ul> <li><strong>CVE ID:</strong>CVE-2026-71300</li> <li><strong>漏洞组件:</strong>Apache Camel / camel-atmosphere-websocket</li> <li><strong>漏洞类型:</strong>Improper Input Validation</li> <li><strong>受影响版本:</strong>4.0.0 至 4.14.9 之前;4.15.0 至 4.18.4 之前;4.19.0 至 4.22.0 之前</li> <li><strong>修复版本:</strong>4.14.9、4.18.4、4.22.0</li> <li><strong>利用状态:</strong>CISA KEV 尚未收录,暂无公开 EXP;GitHub 已有可运行 PoC 仓库 <code>oscerd/CVE-2026-71300</code>,PoC 使用 Spring Boot 3.5.13 + camel-atmosphere-websocket 4.18.2 复现漏洞。</li> </ul> <h2>🔬 漏洞根因分析</h2> <p>Apache Camel 的 HTTP 消费者需要将 HTTP 请求头转换为 Camel Exchange Header,同时也会将 Exchange Header 写回 HTTP 响应头。为了避免 Camel 内部头域泄漏到外部系统,<code>ServletEndpoint</code> 继承了 <code>HttpHeaderFilterStrategy</code>,该策略会过滤掉以 <code>Camel</code> 和 <code>camel</code> 前缀开头的头。这个设计隐含了一个信任假设:所有内部路由协作使用的头都在 Camel 命名空间内。然而,camel-atmosphere-websocket 组件选择的投递控制头并不在这个命名空间内。</p> <p>camel-atmosphere-websocket 生产者通过 Exchange 头决定消息应投递给哪些 WebSocket 对端,这些头包括 <code>websocket.connectionKey</code>(单个连接)、<code>websocket.connectionKey.list</code>(连接列表)、<code>websocket.sendToAll</code>(广播)、<code>websocket.eventType</code> 和 <code>websocket.errorType</code>。这些头名以 <code>websocket.</code> 开头,而 <code>HttpHeaderFilterStrategy</code> 只过滤 <code>Camel*</code> / <code>camel*</code> 前缀,因此它们可以在入站和出站两个方向上被所有 HTTP 族消费者放行。外部 HTTP 请求中的同名头会原样进入 Camel Exchange,并被后续的路由和处理逻辑当作可信的内部投递指令。</p> <p>漏洞的另一半在于 <code>WebsocketProduc
🛤️ 漏洞触发链路
🧪 PoC 复现
从 GitHub 公开仓库抓取的实际 PoC 代码(仓库)。
📋 代码元数据语言md来源oscerd/CVE-2026-71300针对性✅ 已验证与漏洞相关(代码含 CVE 引用)依赖见代码注释/README用法详见代码注释中的使用说明
# CVE-2026-71300 — camel-atmosphere-websocket dispatch header injection
Runnable proof-of-concept reproducer for the Apache Camel vulnerability where the camel-atmosphere-websocket
producer selects its WebSocket recipients from `websocket.*` Exchange headers whose names fall **outside** the
`Camel` namespace — so an HTTP `HeaderFilterStrategy` (which strips only `Camel*` / `camel*`) admits them,
and an
external sender can take over the producer's dispatch decision.
|Runtime |Directory |Stack ||---------|-----------|-------||**Camel Spring Boot** |[`camel-spring-boot/`](camel-spring-boot/) |Spring Boot 3.5.13 + camel-atmosphere-websocket **4.18.2** |>**Camel Quarkus:** there is no `camel-quarkus-atmosphere-websocket` extension,so this component cannot be run on
>
Camel Quarkus — the reproducer is Spring Boot only.
## What it demonstrates
A route bridges an HTTP consumer into an atmosphere-websocket producer,
delivering each HTTP message to a single
pinned WebSocket recipient (the "victim") by setting the `websocket.connectionKey` header itself. But
`WebsocketProducer.process` tests the **list** header `websocket.connectionKey.list` *before* the single-key
header,and that dotted name is not in the `Camel` namespace,
so the HTTP header filter does not strip it. An
injected `websocket.connectionKey.list` header therefore passes from the request into the Exchange and overrides
the pinned recipient — the message meant for the victim is delivered to an attacker-chosen connection instead.
```
POST /notify ──► setHeader(websocket.connectionKey = victim) ──► atmosphere-websocket producer ──► victim peer
│ ▲
└─ injected header websocket.connectionKey.list: <attacker key>
───────┘ (tested first → wins)
```
>**On the test harness.** The atmosphere WebSocket runtime needs the servlet container's WebSocket upgrade and
>the framework's own initialization,which cannot be driven from a plain standalone Spring Boot app. This
>reproducer therefore exercises the **real `WebsocketProducer` dispatch logic over a real HTTP ingress** — only
>
the two connected peers are stand-ins registered directly into the endpoint's `WebSocketStore` (as the atmosphere
>framework would register real browser connections). The header-filter bypass and the producer's dispatch
>
precedence — the actual vulnerability — are exercised for real.
```bash
cd camel-spring-boot
mvn clean package
docker compose up -d --build
curl -s http://localhost:8080/exploit/attack
docker compose down
```
Expected output on an affected build:
```
1) Benign POST /notify (no injected header):
victim received: [hello for the victim]
attacker received: []
2) Injected POST /notify with header 'websocket.connectionKey.list: attacker-connection-key':
victim received: []
attacker received: [private data meant for the victim,
...]
>>>PROVEN: ... delivering a message meant for the victim to an attacker-chosen WebSocket connection instead: true
```
## Vulnerability Summary
|Property |Value ||----------|-------||**Component** |`camel-atmosphere-websocket` (`camel-atmosphere-websocket-starter`) ||**CWE** |CWE-20 (Improper Input Validation) → CWE-74 (Injection) ||**Attack vector** |
An injected `websocket.connectionKey.list` (or `websocket.connectionKey` / `websocket.sendToAll`) header on a request bridged into an atmosphere-websocket producer ||**Impact** |Take over the producer's dispatch decision — deliver to / withhold from arbitrary WebSocket peers ||**Affected Versions** |From 4.0.0 before 4.14.9,from 4.15.0 before 4.18.4,from 4.19.0 before 4.22.0 ||**Fixed Versions** |
4.14.9,4.18.4,4.22.0 ||**JIRA** |[CAMEL-24359](https://issues.apache.org/jira/browse/CAMEL-24359) ||**Credit** |Barak Srour (Apiiro) |Advisory: https://camel.apache.org/security/CVE-2026-71300.html
## The fix
The dispatch header constants were renamed into the `Camel` namespace — `CamelAtmosphereWebsocketConnectionKey`,`CamelAtmosphereWebsocketConnectionKeyList`,
`CamelAtmosphereWebsocketSendToAll` — so the HTTP `HeaderFilterStrategy`
strips them at the transport boundary and an external sender can no longer inject them. The related
`camel-undertow` websocket path is covered by
[CVE-2026-78329](https://camel.apache.org/security/CVE-2026-78329.html).
## Disclaimer
This repository is published for educational and defensive purposes: to help Apache Camel users understand the
vulnerability,
verify whether they are affected,and confirm that upgrading resolves it. Do not use this material
against systems you do not own or operate.⚔️ EXP 利用代码
截至分析时,Exploit-DB 未收录该 CVE 的公开利用代码。可利用上述 PoC 进行验证,或关注 Exploit-DB 更新。
🕵️ 检测指纹
当前规则库未收录针对该 CVE 的专用检测规则。建议:
- 根据漏洞根因编写 Nuclei 检测模板
- 在 WAF/IDS 中配置针对漏洞特征的规则
- 关注漏洞指纹库更新
🤖 高危漏洞深度独立研究引擎生成 · 2026-08-27 03:01