NewApp Monitoring is liveSign up free
AgentbeamBeta
AI agent vulnerability · MCP Python SDK

CVE-2025-53365: MCP Python SDK has Unhandled Exception in Streamable HTTP Transport, Leading to Denial of Service

highCVSS 4.0 8.7GHSA-j975-95f5-7wqh

CVE-2025-53365 lets a remote client crash an MCP server built on the MCP Python SDK (pip package mcp) that uses the streamable HTTP transport. After opening a session, the client triggers an exception that surfaces as an uncaught ClosedResourceError and takes the server down until restart. Versions before 1.10.0 are affected; upgrade to 1.10.0.

Published Jul 4, 2025 · Updated Jul 16, 2026 · Analysis Nov 1, 2026

What an attacker can do

The streamable HTTP transport in the SDK did not catch every exception raised during a session. If a client deliberately causes one after the session is established, the server hits an uncaught ClosedResourceError and the process stops. The fix, pull request 967 titled "Fix uncaught exception in MCP server", adds exception catching. A linked issue in the same repository reports that FastMCP's streamable HTTP server also crashed on unsupported HTTP methods such as HEAD, PUT and DELETE, though the advisory does not say that is the same trigger.

The attacker needs only network access to the MCP endpoint. No authentication, user interaction or privileges are required by the CVSS 4.0 vector, and the result is availability loss only. The advisory notes the real impact depends on the deployment: a server behind a process supervisor that restarts it recovers quickly, while a bare process stays down. An MCP server that backs an AI assistant or agent workflow then goes dark until someone restarts it, and a client can repeat the crash on demand.

Who is affected

The pip package mcp, all versions before 1.10.0, when you run a server over the streamable HTTP transport. Servers that only use stdio are not reachable by remote clients in this way. Check the installed version:

pip show mcp

Also check lock files and container images, since the SDK is often pulled in by other packages that ship MCP servers.

mcp

Ecosystem
PyPI
Affected
< 1.10.0
Fixed in
1.10.0
Check
pip show mcp

How to fix it

Upgrade to mcp 1.10.0:

pip install --upgrade "mcp>=1.10.0"

The fix is in pull request 967 and the v1.10.0 release. The advisory names no workaround beyond infrastructure-level resilience: run the server under a supervisor or orchestrator that restarts it, and do not expose the endpoint to untrusted networks.

How to tell if you were hit

Look in server logs for a traceback ending in anyio.ClosedResourceError followed by process exit, particularly right after a streamable HTTP session was opened. Repeated restarts of the MCP server process, or a container in a crash loop, with HTTP clients you do not recognise in the access log, point to this flaw.

Original advisory

From the GitHub Advisory Database (CC BY 4.0).

If a client deliberately triggers an exception after establishing a streamable HTTP session, this can lead to an uncaught ClosedResourceError on the server side, causing the server to crash and requiring a restart to restore service. Impact may vary depending on the deployment conditions, and presence of infrastructure-level resilience measures.

Thank you to Rich Harang for reporting this issue.

Credited to rharang.

Questions

Which version of the MCP Python SDK fixes CVE-2025-53365?

mcp 1.10.0. Every earlier version is listed as vulnerable.

Does this affect stdio MCP servers?

The advisory describes the streamable HTTP transport, where a remote client opens a session. A server used only over stdio has no such remote session.

Does the attacker need to log in?

The CVSS 4.0 vector says no privileges and no user interaction. Any client that can reach the endpoint and open a session can trigger it, unless you put your own authentication in front.

Can it lead to code execution?

No. The advisory describes a crash and denial of service only.

References

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 MCP Python SDK vulnerabilities

All MCP Python SDK entries