GHSA-f897-62hf-6gxq: MCP TypeScript SDK: HTTP server transports and handlers did not limit request body size or JSON-RPC batch length
The MCP TypeScript SDK put no limit on POST body size or JSON-RPC batch length in its HTTP transports. An unauthenticated client can exhaust memory or stall an MCP server with one huge request or one long batch. Servers that accept Streamable HTTP from untrusted clients are affected. Fixed in @modelcontextprotocol/sdk 1.30.1, and in 2.x server and node 2.1.0 and hono 2.0.1.
Published Oct 27, 2026 · Analysis Oct 27, 2026
What an attacker can do
An MCP server that listens over Streamable HTTP reads the whole POST body before it parses it. Before the fix, nothing capped that body, and nothing capped the number of messages in a JSON-RPC batch. A single oversized request can use up the server's memory. A single batch with a very long list of messages can keep the server busy so that other clients wait.
The attacker needs only network access to the endpoint. No credentials are needed unless your application authenticates requests before they reach the SDK. The result is denial of service: the MCP server crashes or hangs, and every agent that depends on its tools loses them. Nothing in the advisory says data is read or changed (the CVSS vector rates confidentiality and integrity as none).
A body parser such as express.json() does not protect you, because it does not limit batch length. Stdio-only servers are not affected.
Who is affected
Affected: @modelcontextprotocol/sdk 1.10.0 through 1.30.0, and @modelcontextprotocol/server, @modelcontextprotocol/node and @modelcontextprotocol/hono at 2.0.0. You are exposed if clients you do not fully trust can reach your server over Streamable HTTP. Check the installed versions:
npm ls @modelcontextprotocol/sdk @modelcontextprotocol/server @modelcontextprotocol/node @modelcontextprotocol/hono@modelcontextprotocol/sdk
- Ecosystem
- npm
- Affected
- >= 1.10.0, < 1.30.1
- Fixed in
- 1.30.1
- Check
npm ls @modelcontextprotocol/sdk
@modelcontextprotocol/server
- Ecosystem
- npm
- Affected
- >= 2.0.0, < 2.1.0
- Fixed in
- 2.1.0
- Check
npm ls @modelcontextprotocol/server
@modelcontextprotocol/node
- Ecosystem
- npm
- Affected
- >= 2.0.0, < 2.1.0
- Fixed in
- 2.1.0
- Check
npm ls @modelcontextprotocol/node
@modelcontextprotocol/hono
- Ecosystem
- npm
- Affected
- >= 2.0.0, < 2.0.1
- Fixed in
- 2.0.1
- Check
npm ls @modelcontextprotocol/hono
How to fix it
On 1.x, upgrade @modelcontextprotocol/sdk to 1.30.1 or later. On 2.x, upgrade @modelcontextprotocol/server to 2.1.0, @modelcontextprotocol/node to 2.1.0 and @modelcontextprotocol/hono to 2.0.1 or later. Upgrade every one you have installed.
npm install @modelcontextprotocol/[email protected]After the fix, bodies over 4 MiB get a 413 response and batches over 100 messages get a 400. If your clients send larger bodies, raise the new maxRequestBodySize option. If you cannot upgrade yet, cap request body size in a reverse proxy. The advisory names no workaround for batch length.
How to tell if you were hit
Look for an MCP server process whose memory climbs sharply or that restarts after out-of-memory kills. Check access logs or proxy logs for unusually large POST bodies to the MCP endpoint, and for single requests that carry a very long JSON array of messages. Unexplained stalls where other clients time out while one request runs also fit. The advisory does not list log lines for this flaw.
Original advisory
From the GitHub Advisory Database (CC BY 4.0).
Summary
In affected versions, MCP servers reachable over HTTP put no limit on the size of a POST body or on the number of messages in a JSON-RPC batch. Large requests could exhaust the server's memory, and one long batch could block it from serving anyone else. No credentials were needed, unless your application authenticates requests before they reach the SDK.
Am I affected?
Yes, if clients you do not fully trust can reach your server over Streamable HTTP. A body parser such as express.json() does not protect you, because it does not limit batch length. Servers that only use stdio are not affected.
Affected versions:
@modelcontextprotocol/sdk1.10.0 through 1.30.0@modelcontextprotocol/server2.0.0@modelcontextprotocol/node2.0.0@modelcontextprotocol/hono2.0.0
Fix
Upgrade to:
- 1.x:
@modelcontextprotocol/sdk1.30.1 or later - 2.x:
@modelcontextprotocol/server2.1.0,@modelcontextprotocol/node2.1.0 and@modelcontextprotocol/hono2.0.1 or later. Upgrade every one you have installed.
Bodies over 4 MiB now get 413, and batches over 100 messages get 400. If your clients send larger bodies, raise the new maxRequestBodySize option.
If you cannot upgrade yet, cap request body size in a reverse proxy.
Credited to cybercraftsolutionsllc, hewei-gikaku, Jvr2022, Gal3m, mohammad228, shmulc8, JustasMonkev, subchat.
Questions
- Does this need authentication to exploit?
No. The advisory says no credentials are needed, unless your application authenticates requests before they reach the SDK. Any client that can reach the HTTP endpoint can send the oversized body or long batch.
- Are stdio MCP servers affected?
No. Only servers that accept requests over Streamable HTTP are affected. A server that runs over stdio alone has no HTTP body or batch to abuse.
- Does express.json() protect my server?
No. The advisory says a body parser such as express.json() does not limit JSON-RPC batch length. Upgrade the SDK, or at least cap body size in a reverse proxy.
- Will the fix break clients that send large requests?
It can. Bodies over 4 MiB now return 413 and batches over 100 messages return 400. If legitimate clients need more, raise the new maxRequestBodySize option.
References
Read for this analysis:
- https://github.com/modelcontextprotocol/typescript-sdk/pull/2698
- https://github.com/modelcontextprotocol/typescript-sdk/pull/2717
- https://github.com/modelcontextprotocol/typescript-sdk/commit/7b781ed4e25355a25d15974f3c76de81299694ed
- https://github.com/modelcontextprotocol/typescript-sdk/commit/a9f6eb709b85459d01e8f2a9e881fef2621756c1
- https://github.com/modelcontextprotocol/typescript-sdk/releases/tag/1.30.1
- https://github.com/modelcontextprotocol/typescript-sdk/releases/tag/@modelcontextprotocol/[email protected]
- https://github.com/modelcontextprotocol/typescript-sdk/releases/tag/@modelcontextprotocol/[email protected]
- https://github.com/modelcontextprotocol/typescript-sdk/releases/tag/@modelcontextprotocol/[email protected]
- https://github.com/advisories/GHSA-f897-62hf-6gxq
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
Coverage on the Beam blog
- MCP Python SDK: Three Advisories Fixed in 1.30.0 and 2.2.0 (Audience, Redirects, $ref SSRF)
- MCP TypeScript SDK: No Request Body or Batch Limit (GHSA-f897-62hf-6gxq)
- October 2026 Attacks Timeline: Every Breach, Exploit and AI-Run Intrusion, Day by Day
- MCP TypeScript SDK 1.32.0: Four Advisories, Two High, and Fixes That Need Config
- MCP TypeScript SDK OAuth Flaw: A Server Could Collect Your Client Credentials
More MCP TypeScript SDK vulnerabilities
All MCP TypeScript SDK entriesCVE-2026-111767
MCP TypeScript SDK: Experimental tasks were not tied to the session that created them
high8.6Oct 20, 2026CVE-2026-111768
MCP TypeScript SDK: One HTTP request within the default size limit could exhaust server memory during validation
high7.5Oct 20, 2026CVE-2026-111769
MCP TypeScript client SDK: HTTP client transports and OAuth requests followed cross-origin redirects and re-sent custom headers and request bodies
medium6.5Oct 20, 2026CVE-2026-111771
MCP TypeScript SDK: Server bearer authentication accepted tokens issued for another service
medium6.8Oct 20, 2026CVE-2026-104850
MCP TypeScript SDK: OAuth client could send credentials to an authorization server chosen by the MCP server
high7.5Oct 6, 2026CVE-2026-25536
@modelcontextprotocol/sdk has cross-client data leak via shared server/transport instance reuse
high7.1Feb 4, 2026
