Snyk agent scan: MCP Python SDK: HTTP transports serve session requests without verifying the authenticated principal (CVE-2026-52869)
Description
A vulnerability in the MCP Python SDK HTTP transports (SSE and Streamable HTTP in stateful mode) allows session hijacking by bypassing authentication checks. Incoming requests are routed to existing sessions based solely on session IDs without verifying the authenticated principal. This enables an attacker who knows or guesses a session ID to send JSON-RPC messages on that session regardless of the bearer token used. The issue affects versions from 0.4.3 up to but not including 0.5.17. A fix is available in version 1.27.2 or later.
CVSS v3.1
Score 7.1high
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The MCP Python SDK's SSE and Streamable HTTP server transports route incoming requests to existing sessions based only on the session identifier, without verifying that the request is authenticated as the same principal that created the session. This flaw allows an attacker who obtains a session ID to inject JSON-RPC messages into that session, bypassing per-client authentication isolation. The SSE transport has been affected since the first release, and the Streamable HTTP transport since version 1.8.0. The vulnerability requires the server to use bearer-token authentication and stateful HTTP transports. The patch in version 1.27.2 enforces verification of the authenticated principal against the session creator, returning a 404 response if they differ.
Potential Impact
The vulnerability allows an attacker who obtains or guesses a valid session ID to bypass authentication isolation and send messages on behalf of the session owner. This compromises confidentiality and integrity of session data and operations. The impact is high due to the ability to impersonate authenticated clients within the session context. However, exploitation requires out-of-band access to session IDs, which are UUIDs. Servers not using bearer-token authentication or stateless Streamable HTTP transports are not affected.
Mitigation Recommendations
Upgrade the MCP Python SDK to version 1.27.2 or later, which implements verification of the authenticated principal for each session and rejects requests with mismatched principals. For deployments where multiple end users share a single OAuth client, ensure the token verifier populates the AccessToken.subject to isolate sessions per user. Custom authentication backends should implement equivalent principal verification. No other immediate actions are required if the upgrade is applied.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- BREW-snyk-agent-scan-CVE-2026-52869
- Osv Schema Version
- 1.7.3
- Ecosystems
- ["Homebrew"]
- Cvss Version
- 3.1
- State
- PUBLISHED
Threat ID: 6ada44e64d27ba8daa6a52b3
Added to database: 10/22/2026, 17:16:22 UTC
Last enriched: 10/22/2026, 17:28:51 UTC
Last updated: 10/22/2026, 17:28:51 UTC
Views: 3
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.