MCP Ruby SDK: Unbounded JSON-RPC request body causes uncontrolled memory allocation in StreamableHTTPTransport
CVE-2026-67432 · GHSA-h669-8m4g-r2hc · published 2026-07-30
- Severity
- High
- CVSS score
- 7.5
- Chance of exploitation (EPSS)
- 0.78%
- Fixed in
- 0.23.0
- Exploitation No known exploitation
- Automatable Yes
- Technical impact Partial
- CISA SSVC
Attacker requirements: none beyond TCP reach of the MCP endpoint. No session, no credentials, no prior interaction. Effect: memory-exhaustion denial of service. A single request can take a worker offline; sustained low-rate requests keep the service down across worker restarts. On multi-tenant deployments a single attacker tenant can starve neighbours. Affected deployments: every server mounting as a Rack app — the canonical HTTP deployment pattern. Both stateful and stateless: true configurations are affected.
Upgrade mcp to 0.23.0 or later.
1. Reject requests whose Content-Length (or actual read length) exceeds a configurable threshold (e.g. 4 MiB by default) before calling request.body.read. 2. Use a streaming JSON parser, or pass max_nesting: plus a hard byte cap to JSON.parse. 3. Apply the same limit: argument to $stdin.gets in StdioTransport for defence in depth.
| Package | Registry | Affected | Fixed in |
|---|---|---|---|
| mcp | RubyGems | <= 0.22.0 | 0.23.0 |
- HightsParticles: Unbounded HTTP Request Body Buffering in @tsparticles/mcp-server Leads to Remote DoS@tsparticles/mcp-server
- HighMissing request-wide media budget allows single-request frontend resource exhaustionvllm
- HighMCP TypeScript SDK: HTTP server transports and handlers did not limit request body size or JSON-RPC batch length@modelcontextprotocol/hono, @modelcontextprotocol/node, @modelcontextprotocol/sdk, @modelcontextprotocol/server
- HighvLLM : DoS via unvalidated mm_processor_kwargs in multimodal image processors (Isaac, InternVL, H2OVL, etc.)vllm
- HighMCP TypeScript SDK: One HTTP request within the default size limit could exhaust server memory during validation@modelcontextprotocol/sdk, @modelcontextprotocol/server
- HighFrame-count cap bypass in VideoMediaIO.load_base64 for video/jpeg via media_io_kwargs.video.num_framesvllm
- HighMCP Ruby SDK: Ruby SSE Session Poisoningmcp
- HighMCP Ruby SDK: Insufficient Session Binding Allows SSE Stream Hijacking via Session ID Replaymcp
- MediumMCP Ruby SDK: Unbounded session retention in StreamableHTTPTransport allows memory exhaustion via initialize floodmcp
- MediumMCP Ruby SDK: Unbounded line buffer in stdio transports leads to memory exhaustion (DoS)mcp
- MediumMCP Ruby SDK: Streamable HTTP transport lacks DNS-rebinding (Host/Origin) protectionmcp
The impact, patch and workaround text comes from the advisory, shortened (GitHub Advisory Database, CC BY 4.0). Proof-of-concept and reproduction sections and code are left out; the original advisory has them.