CVE-2026-67430: Denial of Service via Unbounded Session Retention in Model Context Protocol Ruby SDK
Vulnerability ID: CVE-2026-67430
CVSS Score: 5.3
Published: 2026-07-30
CVE-2026-67430 is a medium-severity Denial of Service (DoS) vulnerability in the Model Context Protocol (MCP) Ruby SDK (packaged as the mcp gem) versions prior to 0.23.0. In stateful deployments using the StreamableHTTPTransport class, client session states are retained in an in-memory hash map. Because the transport implements a nil idle timeout by default, the background scavenger process is suppressed. Remote, unauthenticated attackers can flood the endpoint with initialize requests, rapidly consuming system memory and triggering an Out-of-Memory (OOM) crash.
TL;DR
Unauthenticated remote attackers can crash stateful MCP Ruby SDK servers by repeatedly triggering new initialize requests. Because the SDK lacks default session limits and idle timeouts, every connection allocates a persistent context in RAM, leading to memory exhaustion and service crashes.
⚠️ Exploit Status: POC
Technical Details
- CWE ID: CWE-770
- Attack Vector: Network (AV:N)
- CVSS v3.1 Score: 5.3
- EPSS Score: 0.00291
- EPSS Percentile: 21.41%
- Impact: Denial of Service (DoS) via memory exhaustion (OOM)
- Exploit Status: PoC Available
- KEV Status: Not Listed
Affected Systems
- Model Context Protocol Ruby SDK (mcp gem) running stateful transports
-
mcp (Ruby SDK): >= 0.6.0, < 0.23.0 (Fixed in:
0.23.0)
Code Analysis
Commit: afb968c
Enforce secure session idle timeouts and concurrent session limits inside StreamableHTTPTransport
Exploit Details
- GitHub Security Advisory GHSA-52jp-gj8w-j6xh: Proof of Concept demonstrating creation of 50,000 sessions in 26.6 seconds causing server OOM
Mitigation Strategies
- Upgrade the mcp gem to version 0.23.0 or later.
- Configure tight session_idle_timeout and max_sessions values on StreamableHTTPTransport initialization.
- Utilize stateless: true if stateful session management is not required.
- Deploy a reverse proxy (e.g., Nginx, HAProxy) in front of the application to enforce request and connection rate-limiting.
Remediation Steps:
- Update your Gemfile to reference mcp version 0.23.0 or later.
- Run bundle update mcp to retrieve and apply the security patch.
- Optionally, explicitly set session_idle_timeout and max_sessions parameters in your StreamableHTTPTransport.new initializer block.
- Restart the Ruby application server to apply the code changes.
References
- GHSA-52jp-gj8w-j6xh: Model Context Protocol Ruby SDK Unbounded Session Retention DoS
- Core Session Hardening Commit
- Release Version 0.23.0 Tag
- CVE-2026-67430 Record
- NVD Entry for CVE-2026-67430
Read the full report for CVE-2026-67430 on our website for more details including interactive diagrams and full exploit analysis.
Top comments (0)