Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-107226 Overview
CVE-2026-107226 is an insecure cookie handling vulnerability in the AsyncHttpClient (AHC) library, a Java HTTP client used to execute asynchronous HTTP requests. The default ThreadSafeCookieStore does not track whether a Set-Cookie response arrived over a secure transport. As a result, the library accepts Secure cookies received over plaintext HTTP and allows insecure cookies to overlay or delete existing Secure cookies that share the same scope. Attackers who control a plaintext same-site response can plant, replace, or remove cookie state later transmitted to an HTTPS origin. The flaw affects AsyncHttpClient versions 2.1.0 through 3.0.13 and is categorized under [CWE-384: Session Fixation].
Critical Impact
Attackers can inject or overwrite Secure cookies via plaintext channels, enabling session fixation, CSRF-token replacement, and loss of security-relevant state on HTTPS origins.
Affected Products
- AsyncHttpClient (AHC) 2.1.0 through 3.0.13
- Java applications using the default ThreadSafeCookieStore
- Downstream libraries and services bundling vulnerable AHC releases
Discovery Timeline
- 2026-10-12 - CVE-2026-107226 published to NVD
- 2026-10-13 - Last updated in NVD database
Technical Details for CVE-2026-107226
Vulnerability Analysis
The AsyncHttpClient library processes Set-Cookie headers through its default ThreadSafeCookieStore implementation. The store does not persist the transport security context in which a cookie was received. Consequently, it fails to enforce the invariant that Secure cookies may only originate from and be modified by secure transports.
The implementation treats all received Set-Cookie headers equivalently regardless of whether the response arrived over HTTP or HTTPS. A plaintext response can therefore deliver a cookie marked Secure, and that cookie will be accepted and later sent to the matching HTTPS origin. The same gap allows an attacker-controlled plaintext response to issue a cookie with the same name and scope as an existing Secure cookie, overwriting or clearing the trusted value.
Root Cause
The root cause is missing enforcement of the cookie Secure attribute semantics defined in RFC 6265bis. The ThreadSafeCookieStore does not record the transport used when storing cookies, so it cannot reject secure-flag cookies from plaintext responses or prevent plaintext cookies from overlaying secure-flag entries.
Attack Vector
An attacker who controls a plaintext same-site response, through network-position interception or a cooperating subdomain served over HTTP, returns a crafted Set-Cookie header. The client stores the cookie without transport validation. On the next HTTPS request to the matching origin, AHC transmits the attacker-planted cookie value. This primitive supports session fixation by pinning a known session identifier, CSRF-token replacement by overwriting anti-CSRF cookies, and silent eviction of integrity-relevant state. No authentication or user interaction is required on the client side. See the GitHub Security Advisory GHSA-p2jm-6hj6-9rjg for additional context.
Detection Methods for CVE-2026-107226
Indicators of Compromise
- Unexpected Set-Cookie headers in plaintext HTTP responses that set the Secure attribute for sensitive application origins.
- Session identifiers or CSRF tokens observed changing between a plaintext response and a subsequent HTTPS request from the same AHC client.
- Application logs showing authenticated sessions bound to session IDs that were never issued by the HTTPS origin.
Detection Strategies
- Inventory Java services and dependencies to identify any transitive use of AsyncHttpClient versions 2.1.0 through 3.0.13.
- Instrument the AHC client or an upstream proxy to log cookie writes, including the scheme of the originating response, and alert on Secure cookies arriving via HTTP.
- Compare outbound HTTPS cookie values against the last values issued by the authoritative origin to flag overlays.
Monitoring Recommendations
- Monitor dependency manifests (pom.xml, build.gradle) in CI pipelines for vulnerable async-http-client coordinates.
- Capture egress traffic from application hosts and alert on plaintext HTTP responses carrying Set-Cookie headers for domains that also serve HTTPS traffic.
- Correlate authentication anomalies with recent cookie-store mutations to identify session fixation attempts.
How to Mitigate CVE-2026-107226
Immediate Actions Required
- Upgrade AsyncHttpClient to version 3.0.14 or later across all applications and transitive dependencies.
- Audit services that cannot be upgraded immediately and disable the default ThreadSafeCookieStore or supply a custom store that enforces Secure semantics.
- Rotate session identifiers and CSRF tokens for applications that interacted with vulnerable AHC clients over mixed-scheme endpoints.
Patch Information
The fix is included in AsyncHttpClient 3.0.14. Review the GitHub Release 3.0.14 and the upstream commit 6ec7ee4 for the implementation details that record transport context and enforce Secure cookie rules.
Workarounds
- Configure applications to communicate exclusively over HTTPS and reject plaintext same-site endpoints that could emit Set-Cookie headers.
- Replace the default cookie store with a custom CookieStore implementation that discards Secure cookies received over plaintext and refuses to overwrite existing Secure entries from HTTP responses.
- Enable HSTS and preloading for all origins consumed by AHC clients to reduce the attacker surface for plaintext interception.
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

