Authorization Bypass Through User-Controlled Key Affecting mcp package, versions <0.23.0


Severity

Recommended
0.0
high
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Authorization Bypass Through User-Controlled Key vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-RUBY-MCP-18017728
  • published19 Jul 2026
  • disclosed17 Jul 2026
  • creditSrikanth Ramu

Introduced: 17 Jul 2026

New CVE NOT AVAILABLE CWE-639  (opens in a new tab)

How to fix?

Upgrade mcp to version 0.23.0 or higher.

Overview

mcp is a The official Ruby SDK for Model Context Protocol servers and clients

Affected versions of this package are vulnerable to Authorization Bypass Through User-Controlled Key in lib/mcp/server/transports/streamable_http_transport.rb, which processes tool execution requests to /messages/{session_id} without verifying that the requester owns the identified session. An attacker who obtains a valid session ID can execute unauthorized tool calls and modify state on a victim's session by sending POST requests to /messages/{session_id}, with the tool responses delivered to the victim's SSE stream. Exploitation requires the attacker to obtain a valid session ID out-of-band, such as through network observation or logs.

CVSS Base Scores

version 4.0
version 3.1