CVE-2026-118259
opentelemetry-java: Quadratic CPU consumption in W3C tracestate parsing
Description
Summary
OpenTelemetry Java's W3C trace-context propagator permits excessive CPU consumption when extracting crafted tracestate headers, potentially leading to denial of service. Regex backtracking causes quadratic parsing time for headers containing long runs of spaces or tabs without a following comma.
Impact
An unauthenticated attacker whose headers reach W3CTraceContextPropagator.extract() can cause excessive CPU usage through crafted requests. Parsing blocks the calling thread, potentially affecting other connections when extraction runs on a shared event-loop thread. Actual impact depends on ingress header-size limits, proxy configuration, and threading. Header-size limits reduce the per-request cost but do not eliminate the vulnerability.
Patches
Upgrade io.opentelemetry:opentelemetry-api to version 1.67.0 or later. PR #8914 replaces regex delimiter splitting with literal comma scanning and explicit whitespace trimming.
Workarounds
If upgrading is not possible, reject or remove oversized tracestate headers before trace-context extraction. This reduces the per-request parsing cost but does not eliminate the risk from repeated requests.
Affected Maven artifacts (1)
| Artifact | Affected versions | Fixed in |
|---|---|---|
| io.opentelemetry » opentelemetry-api | < 1.67.0 | 1.67.0 |
Blast radius
77% of the dependent artifacts (11,776) still pull an affected version in their latest release.
| Depth | Dependent versions |
|---|---|
| Direct | 55,213 |
| 2 hops | 201,297 |
| 3 hops | 249,858 |
| 4 hops | 109,057 |
| 5 hops | 34,542 |
| 6 hops | 11,214 |
Most used dependents
- org.apache.kafka » kafka-clients3,135 usages
- org.seleniumhq.selenium » selenium-java2,089 usages
- com.typesafe.play » play-test1,902 usages
- org.apache.kafka » kafka1,450 usages
- org.scalatestplus.play » scalatestplus-play1,286 usages
- io.opentelemetry » opentelemetry-sdk1,065 usages
- org.apache.kafka » connect-api1,026 usages
- org.apache.hbase » hbase-client960 usages
- com.aliyun.oss » aliyun-sdk-oss791 usages
- com.jetbrains.intellij.platform » ide-impl753 usages
- com.jetbrains.intellij.platform » editor-ui705 usages
- org.apache.hive » hive-exec699 usages
- org.apache.hbase » hbase-common674 usages
- com.jetbrains.intellij.platform » project-model666 usages
- org.apache.kafka » connect-transforms659 usages
Computed from the dependency graph of build 20261124.0621 (compile and runtime scopes, nearest version wins). Exclusions and dependency management in consuming projects are not applied, so dependents are potentially affected. When several artifacts are affected, a dependent version that pulls more than one of them is counted once per artifact.
References
- Webhttps://github.com/open-telemetry/opentelemetry-java/security/advisories/GHSA-ccrj-gw8r-854m
- Webhttps://github.com/open-telemetry/opentelemetry-java/pull/8914
- Webhttps://github.com/open-telemetry/opentelemetry-java/commit/ba4dfea91647d1ef596975db5d7197681df3c0f5
- Webhttps://github.com/open-telemetry/opentelemetry-java/commit/cc4f5f22aed0d69369941cde8029e73507cf438f
- Packagehttps://github.com/open-telemetry/opentelemetry-java
- Webhttps://github.com/open-telemetry/opentelemetry-java/releases/tag/v1.67.0
