CVE-2026-48545: Gradio contains a cookie injection vulnerability
Gradio before 6.15.0 uses one shared HTTP client for its `/proxy=` reverse proxy, so cookies set by one upstream site get stored and replayed to every later proxied request. An attacker who runs any Hugging Face Space can plant a parent-domain cookie that reaches other Spaces for all users of that deployment. Upgrade to gradio 6.15.0.
Published May 27, 2026 · Updated Jul 1, 2026 · Analysis Oct 26, 2026
What an attacker can do
The /proxy= endpoint in gradio/routes.py forwards requests through a module-level httpx.AsyncClient that all users share. That client keeps a cookie jar. If a proxied Space answers with a parent-domain Set-Cookie, the shared client stores it and automatically attaches it to later proxy requests to other, legitimate Spaces (CWE-384, session fixation).
The attacker controls any HF Space and gets a victim's Gradio app to proxy a request to it. They return a parent-domain cookie. From then on, every user of that same Gradio deployment sends that cookie to other Spaces through the proxy. The attacker can fix a session identifier they know, so activity or data in the victim's session on another Space lands in an account the attacker controls or can read.
The CVSS vector rates attack complexity high and needs user participation: someone must reach the attacker's Space through the proxy. Confidentiality and integrity impact are high. Because the client is shared, one successful request affects all users of the deployment, not only the person who triggered it.
Who is affected
The gradio package on PyPI, all versions before 6.15.0. It matters most for deployments that serve the /proxy= endpoint and proxy requests to Spaces you do not control. Check the version:
pip show gradioIf you run Gradio in a container or a Space, check the version pinned in its requirements.txt or image.
gradio
- Ecosystem
- PyPI
- Affected
- < 6.15.0
- Fixed in
- 6.15.0
- Check
pip show gradio
How to fix it
Upgrade to gradio 6.15.0:
pip install --upgrade 'gradio>=6.15.0'The fix is pull request 13384, commit feb7237. It replaces the shared httpx.AsyncClient with a shared AsyncHTTPTransport, which keeps only the connection pool, and builds a fresh client for each /proxy= call through _build_proxy_client(). Each call gets its own cookie jar that is discarded with the streaming response. A new test, test_proxy_clients_do_not_share_cookies, covers this.
The sources give no workaround. Until you upgrade, avoid exposing /proxy= to untrusted Spaces. Restart a long-running server to clear any cookie already stored in the shared client.
How to tell if you were hit
The sources give no log signatures. Check the logs of the Gradio server for /proxy= requests to Spaces that your app has no reason to call. Look at upstream responses that set cookies for a parent domain. On the server, review outbound requests from the proxy for Cookie headers you did not expect. Restarting the process clears the shared jar, so inspect before restarting if you suspect abuse.
Original advisory
From the GitHub Advisory Database (CC BY 4.0).
Gradio before version 6.15.0 contains a cookie injection vulnerability that allows remote attackers to perform cross-Space session fixation by exploiting a shared module-level HTTP client used across all users in the reverse proxy endpoint. Attackers controlling any HF Space can return a parent-domain cookie that the shared client stores and automatically replays into all subsequent proxy requests to other legitimate Spaces, affecting all users of the same Gradio deployment.
Questions
- Who is affected by CVE-2026-48545?
All users of a Gradio deployment before 6.15.0 that serves
/proxy=, because the HTTP client and its cookie jar are shared across all users.- What does the attacker need?
Control of any HF Space that the deployment proxies to, so they can return a parent-domain cookie. The CVSS vector rates attack complexity high and requires user participation.
- Which version fixes it?
gradio 6.15.0. Each proxy request now gets a fresh cookie jar.
- Is it exploited in the wild?
The sources do not say so, and there is no CISA KEV flag. The EPSS score is 0.0035.
References
Read for this analysis:
- https://nvd.nist.gov/vuln/detail/CVE-2026-48545
- https://github.com/gradio-app/gradio/issues/13369
- https://github.com/gradio-app/gradio/commit/feb7237d01f359d2ad4ee42d00344e61692b3b39
- https://www.vulncheck.com/advisories/gradio-cookie-injection-via-shared-pro
- https://github.com/gradio-app/gradio/releases/tag/[email protected]
How this page is made: the data panel comes from the GitHub Advisory Database, CISA’s KEV catalog, the NVD and FIRST EPSS, and updates twice a day. The analysis is written by an AI model from the sources listed above and checked by automated rules before it is published. Check versions against the vendor's advisory before you act. Methodology
More Gradio vulnerabilities
All Gradio entriesCVE-2026-49119
Gradio FileExplorer preprocess path traversal allows files outside root_dir to reach callbacks
high7.5Jul 1, 2026CVE-2026-10783
Gradio: Audio cache key ignores metadata when saving numpy audio outputs
low2.5Jun 4, 2026CVE-2026-27167
Gradio: Mocked OAuth Login Exposes Server Credentials and Uses Hardcoded Session Secret
lowMar 1, 2026CVE-2026-28414
Gradio is Vulnerable to Absolute Path Traversal on Windows with Python 3.13+
high7.5Mar 1, 2026CVE-2026-28415
Gradio has an Open Redirect in its OAuth Flow
medium4.3Mar 1, 2026CVE-2026-28416
Gradio has SSRF via Malicious `proxy_url` Injection in `gr.load()` Config Processing
high8.2Mar 1, 2026
