Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: modelcontextprotocol/typescript-sdk
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v1.25.2
Choose a base ref
...
head repository: modelcontextprotocol/typescript-sdk
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v1.26.0
Choose a head ref
  • 8 commits
  • 16 files changed
  • 8 contributors

Commits on Jan 20, 2026

  1. [v1.x backport] Use correct schema for client sampling validation whe…

    …n tools are present (#1407)
    
    Co-authored-by: Claude Opus 4.5 <[email protected]>
    olaservo and claude authored Jan 20, 2026
    Configuration menu
    Copy the full SHA
    12ae856 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    6e8f7e1 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    6aba065 View commit details
    Browse the repository at this point in the history

Commits on Jan 23, 2026

  1. fix(deps): resolve npm audit vulnerabilities and bump dependencies (v…

    …1.x backport) (#1382)
    
    Co-authored-by: Konstantin Konstantinov <[email protected]>
    samuv and KKonstantinov authored Jan 23, 2026
    Configuration menu
    Copy the full SHA
    aa81a66 View commit details
    Browse the repository at this point in the history

Commits on Feb 2, 2026

  1. Configuration menu
    Copy the full SHA
    50d9fa3 View commit details
    Browse the repository at this point in the history

Commits on Feb 4, 2026

  1. Merge commit from fork

    * fix: add transport isolation guards to prevent cross-client data leaks
    
    When a single McpServer or stateless transport is reused across multiple
    client connections, responses can be routed to the wrong client due to
    message ID collisions. This is a data leak vulnerability (CWE-362).
    
    Two guards added:
    - Protocol.connect() throws if already connected to a transport
    - Stateless transport.handleRequest() throws if called more than once
    
    Also fixes three examples that shared a single McpServer across sessions:
    - standaloneSseWithGetStreamableHttp.ts
    - ssePollingExample.ts
    - elicitationFormExample.ts
    
    Related: #820, #204, #243
    
    Co-Authored-By: Claude Opus 4.5 <[email protected]>
    
    * fix: correct misleading test name and add per-request cleanup
    
    - Rename 'should reject second SSE stream even in stateless mode' to
      'should allow multiple SSE streams in stateless mode with per-request
      transports' since the test now asserts both streams succeed (status 200)
    - Add mcpServer.close() after per-request handling in
      stateManagementStreamableHttp.test.ts to prevent resource leaks,
      matching the pattern used in streamableHttp.test.ts
    - Remove unused mcpServers array that collected but never cleaned up
      per-request server instances
    
    * thread abort through sendRequest and notification to prevent crosstalk
    
    * test: remove dummy objects from stateless setupServer return
    
    In stateless mode, setupServer() was creating unused McpServer and
    StreamableHTTPServerTransport instances solely to satisfy the return
    type. Make mcpServer/serverTransport optional in the return type and
    simplify the stateless beforeEach/afterEach to only track server and
    baseUrl.
    
    * fix: use McpError for sendRequest abort guard and fix Hono example reuse
    
    - sendRequest abort guard now throws McpError(ErrorCode.ConnectionClosed)
      instead of plain Error for consistency with the rest of the codebase
    - Hono example updated to create fresh transport and server per request,
      fixing breakage from the stateless transport reuse guard
    
    * fix: use separate resolvers per protocol in transport isolation test
    
    Address review feedback: each protocol handler now has its own resolver
    returning distinct data (responseForA vs responseForB), so the test
    properly demonstrates that responses route to the correct transport.
    Uses explicit 'handler entered' promises for deterministic synchronization.
    
    ---------
    
    Co-authored-by: Claude Opus 4.5 <[email protected]>
    pcarleton and claude authored Feb 4, 2026
    Configuration menu
    Copy the full SHA
    a05be17 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    4f01e7e View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    fe9c07b View commit details
    Browse the repository at this point in the history
Loading