MCP TypeScript SDK: HTTP server transports and handlers did not limit request body size or JSON-RPC batch length
GHSA-f897-62hf-6gxq · published 27 Oct 2026
How serious is it
- Severity: high, CVSS score 7.5 out of 10.
- No exploit prediction (EPSS) score yet.
- Not on the CISA list of exploited vulnerabilities.
- No public exploit in Exploit-DB.
Is your app affected by GHSA-f897-62hf-6gxq?
Paste this prompt into Claude Code, Cursor or any AI coding tool: it runs a free Shippable scan of your project and fixes what it finds. Built with Lovable, Bolt or v0? Scan your live app. Or upload your package file.
Who is affected
@modelcontextprotocol/sdk(npm) >= 1.10.0, < 1.30.1@modelcontextprotocol/server(npm) >= 2.0.0, < 2.1.0@modelcontextprotocol/node(npm) >= 2.0.0, < 2.1.0@modelcontextprotocol/hono(npm) >= 2.0.0, < 2.0.1
How to check
- Run
npm ls @modelcontextprotocol/sdkin your project to see the installed version, including copies pulled in by other packages. - Run
npm ls @modelcontextprotocol/serverin your project to see the installed version, including copies pulled in by other packages. - Run
npm ls @modelcontextprotocol/nodein your project to see the installed version, including copies pulled in by other packages. - Run
npm ls @modelcontextprotocol/honoin your project to see the installed version, including copies pulled in by other packages. - Or paste your lockfile into the checker: it lists every package with a known vulnerability, this one included.
- Or run
npx shippable-dev scan localhost:3000in your project folder. It reads your lockfile and flags this vulnerability along with every other known one.
How to fix
Copies a prompt for Claude Code, Cursor or Codex: it checks your lockfiles for this and upgrades it.
- On >= 1.10.0, < 1.30.1: Upgrade
@modelcontextprotocol/sdkto 1.30.1 or later, commit the lockfile and redeploy. - On >= 2.0.0, < 2.1.0: Upgrade
@modelcontextprotocol/serverto 2.1.0 or later, commit the lockfile and redeploy. - On >= 2.0.0, < 2.1.0: Upgrade
@modelcontextprotocol/nodeto 2.1.0 or later, commit the lockfile and redeploy. - On >= 2.0.0, < 2.0.1: Upgrade
@modelcontextprotocol/honoto 2.0.1 or later, commit the lockfile and redeploy. - If a vulnerable version was live, check your logs and rotate the secrets that server could read.
The advisory
### 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/sdk` 1.10.0 through 1.30.0
- `@modelcontextprotocol/server` 2.0.0
- `@modelcontextprotocol/node` 2.0.0
- `@modelcontextprotocol/hono` 2.0.0
### Fix
Upgrade to:
- 1.x: `@modelcontextprotocol/sdk` 1.30.1 or later
- 2.x: `@modelcontextprotocol/server` 2.1.0, `@modelcontextprotocol/node` 2.1.0 and `@modelcontextprotocol/hono` 2.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.
Check your whole app
Dependencies are only half of it. Free and read-only: before you push, run npx shippable-dev scan localhost:3000 in your project folder, no account needed. For your live app, you prove it's yours with a one-line tag first.
References
- github.com/modelcontextprotocol/typescript-sdk/security/advisories/GHSA-f897-62hf-6gxq
- github.com/modelcontextprotocol/typescript-sdk/pull/2698
- github.com/modelcontextprotocol/typescript-sdk/pull/2717
- github.com/modelcontextprotocol/typescript-sdk/commit/7b781ed4e25355a25d15974f3c76de81299694ed
- github.com/modelcontextprotocol/typescript-sdk/commit/a9f6eb709b85459d01e8f2a9e881fef2621756c1
- github.com/modelcontextprotocol/typescript-sdk/releases/tag/1.30.1
- github.com/modelcontextprotocol/typescript-sdk/releases/tag/@modelcontextprotocol/hono@2.0.1
- github.com/modelcontextprotocol/typescript-sdk/releases/tag/@modelcontextprotocol/node@2.1.0
- github.com/modelcontextprotocol/typescript-sdk/releases/tag/@modelcontextprotocol/server@2.1.0
- github.com/advisories/GHSA-f897-62hf-6gxq
- github.com/modelcontextprotocol/typescript-sdk
Merged from GitHub Advisory Database, OSV. Last updated 28 Oct 2026. All vulnerabilities · RSS · JSON