When making any HTTP request, the automatically enabled and self-managed CookieStore
(aka cookie jar) will silently replace explicitly defined Cookie
s with any that have the same name from the cookie jar. For services that operate with multiple users, this can result in one user's Cookie
being used for another user's requests.
This issue is described without security warnings here:
https://github.com/AsyncHttpClient/async-http-client/issues/1964
I already have a PR to fix this issue:
https://github.com/AsyncHttpClient/async-http-client/pull/2033
Cookie
to the CookieStore
Set-Cookie
, as shown in issue #1964 above.Cookie
is provided as a passthrough, like a JWT, and attempt to use it by explicitly providing it.This is generally going to be a problem for developers of backend services that implement third party auth features and use other features like token refresh. The moment a third party service responds by setting a cookie in the response, the CookieStore
will effectively break almost every follow-up request (hopefully by being rejected, but possibly by revealing a different user's information).
If your service sets cookies based on the response that happens here, it's possible to lead to even greater levels of exposure.
{ "nvd_published_at": "2024-12-02T18:15:11Z", "cwe_ids": [ "CWE-287" ], "severity": "CRITICAL", "github_reviewed": true, "github_reviewed_at": "2024-12-02T20:04:43Z" }