Skip to content

Http4s: CookieJar middleware accepts arbitrary Set-Cookie domain

Moderate severity GitHub Reviewed Published Jul 6, 2026 in http4s/http4s • Updated Sep 15, 2026

Package

maven org.http4s:http4s-client_2.12 (Maven)

Affected versions

<= 0.23.34

Patched versions

0.23.35
maven org.http4s:http4s-client_2.13 (Maven)
<= 0.23.34
>= 1.0.0-M1, <= 1.0.0-M46
0.23.35
1.0.0-M47
maven org.http4s:http4s-client_3 (Maven)
>= 1.0.0-M1, <= 1.0.0-M46
<= 0.23.34
1.0.0-M47
0.23.35

Description

When processing a Set-Cookie from a response, the CookieJar client middleware trusts the server-supplied Domain attribute verbatim, with no check that it domain-matches the host that sent the cookie (RFC6265 §5.3 step 6) and no public suffix check. A malicious or compromised server can therefore plant a cookie for any domain in the cookie jar, which is subsequently set on the client's next request to that victim domain, enabling session fixation or overwriting security-relevant cookies.

Impact

Session fixation and overwrite of security-relevant cookies for arbitrary domains contacted by the same wrapped client.

Preconditions

  • Application uses the CookieJar client middleware.
  • Application contacts an attacker-controlled (or compromised) server using the same jar it uses for trusted hosts.

Workarounds

  • Do not share a CookieJar across trusted and untrusted targets.

Note

This middleware still does not implement public suffix rejection.

References

@rossabaker rossabaker published to http4s/http4s Jul 6, 2026
Published to the GitHub Advisory Database Sep 15, 2026
Reviewed Sep 15, 2026
Last updated Sep 15, 2026

Severity

Moderate

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Network
Attack complexity
High
Privileges required
None
User interaction
None
Scope
Changed
Confidentiality
None
Integrity
High
Availability
None

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:N/I:H/A:N

EPSS score

Exploit Prediction Scoring System (EPSS)

This score estimates the probability of this vulnerability being exploited within the next 30 days. Data provided by FIRST.
(31st percentile)

Weaknesses

Session Fixation

Authenticating a user, or otherwise establishing a new user session, without invalidating any existing session identifier gives an attacker the opportunity to steal authenticated sessions. Learn more on MITRE.

Reliance on Cookies without Validation and Integrity Checking

The product relies on the existence or values of cookies when performing security-critical operations, but it does not properly ensure that the setting is valid for the associated user. Learn more on MITRE.

CVE ID

CVE-2026-69214

GHSA ID

GHSA-wv64-j4fq-5f9x

Source code

Credits

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.