@modelcontextprotocol/sdk · MCP TypeScript SDK: HTTP server transports and handlers did not limit request body size or JSON-RPC batch length
Affects @modelcontextprotocol/sdkSource GCVE Database
CVSS 7.5 High : upgrade to 1.30.1 soon.
Data as of 27 Oct 2026, 20:29 UTC
- Patch
- Available – fixed in 1.30.1, 2.1.0, 2.0.1
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:HWhat to do
Upgrade @modelcontextprotocol/sdk to 1.30.1; @modelcontextprotocol/server and @modelcontextprotocol/node to 2.1.0; @modelcontextprotocol/hono to 2.0.1.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| npm@modelcontextprotocol/sdk | Affected
| Fixed in
|
| npm@modelcontextprotocol/server | Affected
| Fixed in
|
| npm@modelcontextprotocol/node | Affected
| Fixed in
|
| npm@modelcontextprotocol/hono | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
AI-suggested
Upgrade all affected MCP packages to the fixed versions: @modelcontextprotocol/sdk to 1.30.1 or later, @modelcontextprotocol/server and @modelcontextprotocol/node to 2.1.0 or later, and @modelcontextprotocol/hono to 2.0.1 or later. These versions enforce a 4 MiB maximum request body size and a maximum of 100 messages per JSON-RPC batch. If upgrading is not immediately possible, implement request body size limits in a reverse proxy in front of the server to prevent large requests from reaching the application.
Description
Certain versions of the MCP TypeScript SDK and related packages do not limit HTTP POST request body size or JSON-RPC batch length. This allows an attacker to send very large requests or long batches, potentially exhausting server memory and causing denial of service. No authentication is required unless implemented outside the SDK. Fixed versions impose limits on request size and batch length.
References
- github.com/modelcontextprotocol/typescript-sdk/security/advisories/GHSA-f897-62hf-6gxq (opens in a new tab)
- github.com/modelcontextprotocol/typescript-sdk/pull/2698 (opens in a new tab)
- github.com/modelcontextprotocol/typescript-sdk/pull/2717 (opens in a new tab)
- github.com/modelcontextprotocol/typescript-sdk/commit/7b781ed4e25355a25d15974f3c76de81299694ed (opens in a new tab)
- github.com/modelcontextprotocol/typescript-sdk/commit/a9f6eb709b85459d01e8f2a9e881fef2621756c1 (opens in a new tab)
- github.com/modelcontextprotocol/typescript-sdk (opens in a new tab)
- github.com/modelcontextprotocol/typescript-sdk/releases/tag/1.30.1 (opens in a new tab)
- github.com/modelcontextprotocol/typescript-sdk/releases/tag/@modelcontextprotocol/hono@2.0.1 (opens in a new tab)
- github.com/modelcontextprotocol/typescript-sdk/releases/tag/@modelcontextprotocol/node@2.1.0 (opens in a new tab)
- github.com/modelcontextprotocol/typescript-sdk/releases/tag/@modelcontextprotocol/server@2.1.0 (opens in a new tab)