You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(mcp): restrict MCP server destination changes to admins - #8629
Changing an MCP server's destination (origin or path) now requires workspace admin; query-string edits and every other field stay at write
Enforced in updateMcpServer via a required allowDestinationChange flag, so the settings PATCH route, the Copilot edit, and the v2 update all hit the same check
Use cases authorize the new admin-only mcp_servers.change_destination operation before writing; the legacy route derives the flag from the caller's role
Registering a server whose hashed id collides with an existing row at a different destination is now refused instead of repointing that row
Type of Change
Bug fix
Testing
Unit tests for writer refusal, admin path, query-string-only edits, route role mapping, and the id-collision refusal
bun run lint, bun run check:audits, block registry and docs-manifest checks pass
[Critical risk] Restricts MCP server destination changes to admin role.
The PR appears safe to merge based on this review.
Summary
The PR restricts MCP server destination changes to workspace admins, permits query-string-only edits for writers, and rejects registration when a server ID collides with a different destination. Since the previous review, the only change replaces a relative test import with the configured path alias.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
writeupdateMcpServervia a requiredallowDestinationChangeflag, so the settings PATCH route, the Copilot edit, and the v2 update all hit the same checkmcp_servers.change_destinationoperation before writing; the legacy route derives the flag from the caller's roleType of Change
Testing
bun run lint,bun run check:audits, block registry and docs-manifest checks passChecklist
🤖 Generated with Claude Code
https://claude.ai/code/session_01QFCu7AdYKDS9qmX4qaJg2e