Advisory Database
  • Advisories
  • Dependency Scanning
  1. pypi
  2. ›
  3. fastapi-proxy-lib
  4. ›
  5. GMS-2023-5457

GMS-2023-5457: Cookie leakage between different users in fastapi-proxy-lib

December 1, 2023

Impact

In the implementation of version 0.0.1, requests from different user clients are processed using a shared httpx.AsyncClient.

However, one oversight is that the httpx.AsyncClient will persistently store cookies based on the set-cookie response header sent by the target server and share these cookies across different user requests.

This results in a cookie leakage issue among all user clients sharing the same httpx.AsyncClient.

Patches

It’s fixed in 0.1.0

Workarounds

If you insist 0.0.1:

  • Do not use ForwardHttpProxy at all.
  • Do not use ReverseHttpProxy or ReverseWebSocketProxy for any servers that may potentially send a set-cookie response.

However, it’s best to upgrade to the latest version.

References

fixed in #10

References

  • github.com/WSH032/fastapi-proxy-lib/pull/10
  • github.com/WSH032/fastapi-proxy-lib/security/advisories/GHSA-7vwr-g6pm-9hc8
  • github.com/advisories/GHSA-7vwr-g6pm-9hc8

Code Behaviors & Features

Detect and mitigate GMS-2023-5457 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 0.1.0

Fixed versions

  • 0.1.0

Solution

Upgrade to version 0.1.0 or above.

Source file

pypi/fastapi-proxy-lib/GMS-2023-5457.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 14 May 2025 12:15:38 +0000.