Repository navigation
fix(deps): bump @mcp-b/global to 6.1.0 to clear @modelcontextprotocol/server advisories - #7742
Conversation
…/server advisories @mcp-b/global 5.x and 6.0.x pin @modelcontextprotocol/server 2.0.0, which is affected by GHSA-f897-62hf-6gxq, GHSA-46jr-4wx8-v453, GHSA-jm63-cq47-j5jp and GHSA-rvq5-wwqv-78pq (>=2.0.0 <2.3.0). 6.1.0 is the first release that pins server 2.4.0. 6.x installs the W3C WebMCP polyfill and passes { signal } to execute; the real-package tests now drive the 6.x surface (secure context, MCP tools/call). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
6.x's BrowserMcpServer sends a tools-changed event on a timer after the last tool unregisters. Without cleanupWebModelContext() it fired after jsdom teardown and vitest failed the run on an unhandled rejection. Also scope the transport test's header to the MCP transports it actually checks. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
jrusso1020
left a comment
There was a problem hiding this comment.
Reviewed at 8b45961
Need: yes · Size: dependency update plus compatible tests/comments · Reuse: existing Studio polyfill loader, registration and transport policy · Simpler: already minimal · Structure: fine (checked loader, hook, registrar and the new dependency's frame policy; no split)
Risk: medium — changes the browser agent bridge and drops fallback support in unsupported contexts.
The lock changes are limited to the MCP bridge family, MCP server/core 2.4.0, the W3C polyfill/types, their zod resolution and removed obsolete type dependencies. The only dependency declaration change is Studio's @mcp-b/global range.
I traced the actual Studio caller: native document.modelContext bypasses the dynamic import. If the real 6.x package does not install, loadModelContextPolyfill() reports webmcp.polyfill_failed and returns null; useStudioAgentTools() exits without registering tools. The editor remains mounted. Thus plain HTTP on a LAN address and older browsers lose this agent bridge, rather than losing Studio. This is a browser capability change despite unchanged editor UI.
The existing MCP tab transport remains same-window/same-origin, and iframeServer:false is honored. The separate new W3C frame protocol is not disabled by that option; its registered tools default to no cross-origin exposure, with origin checks on discovery/execution. The updated transport test covers MCP traffic, not that separate W3C protocol. The real-package save test now exercises JSON-RPC tools/call instead of removed 5.x internals; existing input-only and abort tests remain.
Validation: clean frozen install, full build and Studio typecheck passed. WebMCP tests 185 passed across 17 files: the committed 183 tests plus two temporary review probes using the real package and Studio hook, one insecure and one simulating missing older-browser URL.parse. Both probes kept the editor mounted, installed no modelContext and observed the expected failure telemetry. Probes were removed afterward. This is jsdom validation, not a native Safari or signed-in dev walkthrough. Independent code review found no blocker.
Base-versus-head bun audit --json confirms removal of the named three MCP-server highs and one moderate, with no new advisory; MCP server/core resolve to 2.4.0. The request-size advisory, validation advisory, and shared-transport advisory ranges exclude that server version. Other vulnerable packages remain outside this update.
Nit: mention the insecure-context/older-browser agent-bridge restriction in release notes so users do not interpret missing tools as an editor failure.
Verdict: APPROVE
Reasoning: the patched dependency remains compatible with Studio's tool boundary and preserves a working editor when the fallback is unavailable.
— Rames
What
Bumps
@mcp-b/globalin@hyperframes/studiofrom^5.0.1to^6.1.0, so@modelcontextprotocol/serverand@modelcontextprotocol/coreresolve to 2.4.0 instead of 2.0.0. Updates the WebMCP tests and comments for the 6.x behavior.Why
@modelcontextprotocol/server2.0.0 is affected by:>=2.0.0 <2.1.0)>=2.0.0 <2.3.0)>=2.0.0 <2.3.0)>=2.0.0 <2.3.0)Every
@mcp-b/global5.x release and 6.0.x exact-pin@modelcontextprotocol/server2.0.0, so neither a lock refresh nor an override inside 5.x can clear these. 6.1.0 is the first release that pins 2.4.0. Dependabot does not raise these (it reads only workspacepackage.jsonranges);bun auditdoes.Related work
No open Renovate PR covers
@mcp-b/global. A separate lock-refresh PR clears the otherbun audithighs (zod, smol-toml, aws-cdk-lib); both touchbun.lock, so whichever lands second needs a lock re-merge.How
packages/studio/package.json:@mcp-b/global^6.1.0.bun.lock:@mcp-b/*5.0.1 -> 6.1.0,@modelcontextprotocol/server/core2.0.0 -> 2.4.0 (with zod 4.6.7 under them), adds@w3c/webmcp-polyfill0.1.0 andwebmcp-types0.1.10, drops@mcp-b/webmcp-typesand its@types/*deps.6.x installs the W3C WebMCP polyfill and calls
execute(input, { signal }). Studio handlers already treatoptionsas optional, so no runtime code changed; comments that described 5.x-only behavior now say "before 6.0".The real-package tests drive the 6.x surface: the polyfill only installs in a secure context (jsdom leaves
isSecureContextundefined, so the tests set it), and the write-tool test now goes through an MCPtools/callover the tab transport instead of the 5.x bridge registry.useStudioAgentTools.polyfill.test.tsxgoes from two cases to one: the dropped case drove the 5.x native-modelContextmirror and.toolsregistry, which 6.x no longer has and Studio never reaches (it loads the polyfill only when the browser has no nativemodelContext). The kept case asserts a real save through MCPtools/call; the "input alone" regression test inuseStudioAgentTools.test.tsxstays.The suite now calls
cleanupWebModelContext()inafterAll, because 6.x sends a deferred tools-changed event that otherwise fires after jsdom teardown.Behavior change: 6.x does not install outside a secure context (for example Studio over plain
httpon a LAN IP) or on browsers withoutPromise.withResolvers/AbortSignal.any/URL.parse(such as Safari before 18). There Studio's loader already degrades cleanly: no agent tools, and it reports the existingwebmcp.polyfill_failedevent. Studio's own-page-only transport settings (iframeServer: false,tabServer.allowedOrigins) are unchanged and still honoured, and Studio passes noexposedTo, so a framing site is offered no tools.Release age:
@mcp-b/global/transports/webmcp-polyfill/webmcp-ts-sdk6.1.0 published 2026-11-10;@modelcontextprotocol/server2.4.0 2026-10-23;@w3c/webmcp-polyfill0.1.0 2026-11-03;webmcp-types0.1.10 2026-09-28. All at least three days old.No visible change
Dependency bump plus comment updates in
types.tsanduseStudioAgentTools.ts; no UI code changes. Studio renders the same; only the agent-facing WebMCP polyfill underneath it changes version.Test plan
bun install --frozen-lockfilebun why @modelcontextprotocol/server: only 2.4.0bun auditbefore/after: the three high and one moderate@modelcontextprotocol/serveradvisories are goneNODE_ENV=testvitest run src/webmcpin studio: 16 files, 183 tests passed, run exits 0 (3 consecutive runs), including the real-package polyfill and transport teststsc --noEmit🤖 Generated with Claude Code