Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSend repeated HTTP initialize requests
-
DeliveryAllocate unbounded ServerSession objects per request
-
ExploitFill Ruby heap with unreleased session objects
-
ExecutionTrigger OS out-of-memory condition
-
ImpactProcess crash denies service to all MCP clients
Vulnerability Assessment
| Weakness |
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Resource cleanup, leak prevention
|
| Exploitation Conditions | The target must be running a version of the mcp Ruby gem prior to 0.23.0 with MCP::Server::Transports::StreamableHTTPTransport in stateful mode (stateless: false, the default). The HTTP initialize endpoint must be network-reachable by the attacker - if the server is behind an authenticating reverse proxy or not exposed externally, unauthenticated exploitation is blocked at the network layer. No user interaction, special protocol knowledge, or prior session state is required. Stateless mode (stateless: true) is explicitly immune regardless of version. The limiting factor for impact is available process memory and host OOM behavior: on systems with large memory allocations or OOM score adjustments, memory exhaustion may be slow or incomplete before the process is killed. |
| Impact | The CVSS vector (AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L) accurately reflects the network-accessible, zero-authentication, low-complexity attack surface, but the official A:L rating may understate impact: sustained initialize flooding can fully exhaust process memory and crash the Ruby process, which is closer to A:H behavior. No EPSS data was provided. The vulnerability is not in CISA KEV and no public exploit code has been identified, suggesting no current widespread exploitation. Despite the unauthenticated network vector, real-world risk is moderated by deployment context: MCP SDK servers are predominantly internal AI agent infrastructure or developer tooling, rarely exposed directly to the internet without a reverse proxy or auth layer. The attack is fully automatable (no special tooling required), which raises urgency for any internet-facing deployment. Patch availability as of v0.23.0 eliminates the risk with no required configuration change, as secure defaults are now applied automatically. |
| Exploit ScenarioDerived | An attacker sends a continuous stream of HTTP initialize requests to the StreamableHTTPTransport endpoint without ever issuing DELETE requests. Each request allocates a new ServerSession object retained indefinitely in the session hash. Over time, the Ruby process's heap grows until the OS OOM-kills the process, denying service to legitimate MCP clients. No authentication, special tooling, or prior knowledge of the target is required - a simple loop with curl or a script suffices. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Jul 29, 2026
Unbounded session growth in MCP Ruby SDK's StreamableHTTPTransport allows unauthenticated remote attackers to exhaust server process memory by repeatedly sending initialize requests. Affected versions prior to 0.23.0 defaulted to no session expiry and no concurrent session cap, meaning each initialize request created a persistent ServerSession object that was never reclaimed without an explicit client DELETE. No public exploit has been identified at time of analysis, and exploitation is not confirmed by CISA KEV, but the attack is trivially automatable given the network-accessible, unauthenticated HTTP endpoint.
RemediationAI
Upgrade the mcp gem to version 0.23.0 or later; the fix is published at https://github.com/modelcontextprotocol/ruby-sdk/releases/tag/v0.23.0. Version 0.23.0 applies secure defaults automatically (30-minute idle timeout, 10,000 session cap) without requiring any configuration changes. As an interim workaround on earlier versions, explicitly pass session_idle_timeout: 1800 and enforce a session cap at the application or reverse-proxy layer (e.g., rate-limit POST /initialize requests per source IP in nginx or a WAF) to prevent unbounded session growth. Placing the MCP server behind an authenticated reverse proxy eliminates the unauthenticated attack surface entirely. Note that opting out of expiry with session_idle_timeout: nil or max_sessions: nil on internet-facing deployments is explicitly discouraged by the SDK maintainers as of v0.23.0.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 2 packages in rubygems, euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
The Model Context Protocol (MCP) Ruby SDK (CPE: cpe:2.3:a:modelcontextprotocol:ruby-sdk) implements a StreamableHTTPTransport that maintains stateful server sessions keyed by session ID in an in-process hash map. Each initialize HTTP request allocates a ServerSession object that is stored indefinitely until the client sends an explicit DELETE. CWE-401 (Missing Release of Memory After Effective Lifetime) applies: the SDK lacked both an idle timeout and a maximum concurrent session count, so the session store grew without bound. The fix in v0.23.0 introduces DEFAULT_SESSION_IDLE_TIMEOUT of 1800 seconds (30 minutes), DEFAULT_MAX_SESSIONS of 10,000, a background reaper thread that collects expired sessions approximately once per minute, and a 503 rejection path when the cap is hit after reclaiming already-expired slots. Stateless mode (stateless: true) is unaffected as it retains no session state.
Know when Ruby Sdk gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
Unauthenticated network access with no complexity; memory exhaustion can crash the process entirely, warranting A:H over official A:L.
Primary rating from Vendor (GitHub_M).
CVSS VectorVendor: GitHub_M
Lifecycle Timeline
1DescriptionCVE.org
MCP Ruby SDK is the official Ruby SDK for Model Context Protocol servers and clients. Prior to 0.23.0, MCP::Server::Transports::StreamableHTTPTransport in the mcp gem does not expire sessions by default, so repeated initialize requests retain unbounded ServerSession objects and can exhaust process memory. This issue is fixed in version 0.23.0.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.
Session hijacking in the MCP Ruby SDK (mcp gem) before 0.23.0 lets an attacker who obtains a valid session ID issue tool
Uncontrolled memory allocation in the official Model Context Protocol Ruby SDK (mcp gem) before 0.23.0 lets an unauthent
DNS rebinding in MCP Ruby SDK's StreamableHTTPTransport (mcp gem, all versions prior to 0.23.0) exposes locally running
Uncontrolled memory growth in the MCP Ruby SDK (mcp gem) prior to 0.23.0 allows any peer process communicating via stdio
EUVD-2026-50498
GHSA-52jp-gj8w-j6xh
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB