Apache Camel Keycloak policy accepts expired tokens from cache
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- Security bypass
- Confidentiality · integrity · availability
- Low · Low · None
- Fix status
- Fixed
Attack profile from CVSS 3.1 · NVD. Fix status from CNA. Impact type from CWE-613.
Summary
Apache Camel from 4.16.0 before 4.18.5 and from 4.19.0 before 4.22.2 accepts expired access tokens when token introspection is enabled on the camel-keycloak KeycloakSecurityPolicy. Both cache implementations keep an introspection result for a fixed time (introspectionCacheTtl, 60 seconds by default) without bounding it by the token's exp claim, as RFC 7662 requires. KeycloakSecurityProcessor checks only the active flag, so a token cached while still active can be admitted with its roles for up to the TTL after expiry. The issue allows no token forgery or privilege escalation, and the local JWT path is not affected. (CWE-613)
Written with Claude Haiku 5.5 from the sources below · 2026-11-06
Description from the CNA
Insufficient Session Expiration vulnerability in Apache Camel Keycloak component. This issue affects Apache Camel: from 4.16.0 before 4.18.5, from 4.19.0 before 4.22.2. When token introspection is enabled on the camel-keycloak KeycloakSecurityPolicy (useTokenIntrospection=true), the security processor validates the access token of a request by sending it to Keycloak's OAuth 2.0 token introspection endpoint, and accepts the token while the response reports it as active. The introspection endpoint reports a token as inactive once its exp (expiration) time has passed, so on this path the active flag is what enforces token expiry. Introspection results are cached by default (introspectionCacheEnabled=true, introspectionCacheTtl=60 seconds), and both cache implementations shipped with the component, ConcurrentMapTokenCache and CaffeineTokenCache, expired an entry a fixed time after it was inserted, without bounding that lifetime by the exp claim that the cached response already carried. KeycloakSecurityProcessor in turn checked only the active flag of the result, on every path that uses introspection, and never compared exp with the current time. A response cached shortly before the token expired was therefore served to later requests carrying the same token for up to the configured time-to-live after the token's expiry, and those requests were admitted with the roles and permissions the expired token had carried, although RFC 7662, which defines token introspection, states that a response containing exp must not be cached beyond that time. The access token is supplied by the caller with each request, typically as a bearer token in the Authorization header, so a caller holding a token that was valid moments earlier could keep using it after it expired, for as long as the cached entry lived. The window is bounded by introspectionCacheTtl, which is 60 seconds by default and 300 to 600 seconds where the documentation's recommendation for internal services was followed, and it opens only for a token that the same Camel process introspected and cached while the token was still active. The issue grants nothing beyond what the token already carried: it allows no token forgery and no privilege escalation, and token introspection is not enabled by default, which is why the severity is assessed medium. The local JWT verification path, used when introspection is disabled, is not affected by this issue. 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.2. If users are on the 4.18.x releases stream, then they are suggested to upgrade to 4.18.5. The 4.16.x, 4.17.x and 4.19.x to 4.21.x release lines reached end of life before this issue was resolved and will not receive a fix, so deployments on them must move to a supported release. For deployments that cannot upgrade immediately, set introspectionCacheEnabled=false on the KeycloakSecurityPolicy, so that every request is checked against the introspection endpoint, which reports an expired token as inactive, at the cost of one introspection call per request. Lowering introspectionCacheTtl only narrows the window and does not close it.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
Remediation
Upgrade to 4.23.0, or to 4.22.2 on the 4.22.x stream or 4.18.5 on the 4.18.x stream. The 4.16.x, 4.17.x and 4.19.x to 4.21.x lines are end of life and will not receive a fix, so move them to a supported release. If an upgrade cannot happen yet, set introspectionCacheEnabled=false on the KeycloakSecurityPolicy.
Written with Claude Haiku 5.5 from the sources below · 2026-11-06
- Fix · CNA Apache Camel (Apache Software Foundation) Fixed in 4.18.5, 4.22.2
Fixed in the same release
Records fixed by the same vendor advisory or release, as the CNA lists them.
- Release ·
Apache Camel 4.18.5, 4.22.2
6 records Highest priority Priority MEDIUM 1 MEDIUM, 5 LOW
Other records, highest priority first
- TI-2026-80421 XML external entity resolution in Apache Camel XQuery evaluationPriority MEDIUM 40
- TI-2026-80294 Apache Camel CoAP consumer leaks internal details in error responsesPriority LOW 31
- TI-2026-80293 Expression language injection in Apache Camel AWS2 S3 producerPriority LOW 26
Timeline
- 2026-10-26 Threatist record created from CVE-2026-95663
- 2026-10-27 Alias added: GHSA-44m5-wqhm-rq65
- 2026-11-02 CISA SSVC decision points changed
- 2026-11-06 CVSS score added · NVD
- 2026-11-07 EPSS moved to the 50th–90th percentile
References
Patch 3
More Apache Camel vulnerabilities
- TI-2026-76322 Unsafe deserialization in Apache Camel camel-hazelcast CVSS 4.0CRITICAL 10.0
- TI-2026-18973 Apache Camel: Camel-Keycloak: Cross-Realm Token Acceptance Bypass in KeycloakSecurityPolicy CVSS 3.1CRITICAL 9.1
- TI-2026-76339 Path traversal in Apache Camel azure-files component CVSS 3.1CRITICAL 9.1
- TI-2026-76330 Path traversal in Apache Camel FTP consumer escapes polled directory CVSS 3.1CRITICAL 9.1
- TI-2025-20435 Apache Camel: Camel Message Header Injection via Improper Filtering CVSS 3.1MEDIUM 5.6
- TI-2026-34899 Apache Camel: Camel-CXF Message Header Injection via Missing Inbound Filtering CVSS 3.1CRITICAL 9.8
Sources
- CVE-2026-95663 · CVE Program
- CVE-2026-95663 · NVD
- FIRST EPSS
- GHSA-44m5-wqhm-rq65 · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences