OAuth middleware endpoints bypass request body limits and allow unauthenticated memory exhaustion
GHSA-f4rf-6ghj-mhr6 · published 2026-11-10
- Severity
- Low
- CVSS score
- 3.7
- Chance of exploitation (EPSS)
- No CVE
- Fixed in
- 0.9.0
The affected endpoints are intentionally reachable before bearer-token authentication. A remote unauthenticated attacker can force a PHP worker to allocate multiple times the supplied request size. Depending on the PHP SAPI and process model, one or repeated requests can terminate workers, exhaust a shared memory budget, increase upstream traffic, and degrade or deny the MCP service. The demonstrated request-to-peak ratio for the combined 16 MiB proof was approximately 8.5x (about 136 MiB peak), although exact amplification varies by PHP version, SAPI, allocator, and which endpoint is exercised. …
Upgrade mcp/sdk to 0.9.0 or later.
Enforce a shared request-body limit before any route-specific middleware can consume a body. The safest design is an outermost body-limiting middleware used by every POST endpoint, including /token, /register, and future well-known or proxy handlers. The limiter should: 1. Reject a declared Content-Length above the configured limit before reading. 2. Still stream and count the body with a hard cutoff, because chunked requests can omit or lie about Content-Length. 3. Return HTTP 413 without parsing, decoding, rebuilding, logging, or forwarding the oversized body. 4. Apply one documented configuration consistently across the transport and OAuth endpoints. …
| Package | Registry | Affected | Fixed in |
|---|---|---|---|
| mcp/sdk | Packagist | >= 0.8.0, <= 0.8.1 | 0.9.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
- HighUnbounded session retention in the Streamable HTTP transport allows an initialize flood DoSio.modelcontextprotocol.sdk:mcp-core
- HighUnauthenticated unbounded tool_schemas cache growth in rmcp Streamable HTTP server transport leads to remote denial-of-servicermcp
The impact, patch and workaround text comes from the advisory, shortened (published by the MCP PHP SDK project). Proof-of-concept and reproduction sections and code are left out; the original advisory has them.