mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
fix: harden org-scoped MCP config chat gating, updates, and visibility (#28065)
Hardens the org-scoped MCP server config surface from #27942 with fixes and regression pins that are independent of the core cutover: - Keep chats sendable after a selected MCP server is disabled (persisted selections are exempt from message-time rejection). - Keep cached MCP selections usable after a background refetch error (gate the composer on missing data, not `isSuccess`). - Merge PATCH updates onto the current row so unset fields are not clobbered. - Give auditors the full management view of MCP configs their audit logs reference (site and org auditor roles). - Regression pins: frozen OAuth2 callback path, cross-org concealment for item routes, OAuth callback token binding, and disconnect responses indistinguishable from nonexistent config IDs. - Storybook: semantic textbox queries in MCP loading stories; docs note that the MCP settings page needs deployment access. ## Stack context Part of the MCP org-separation stack (CODAGT-711 org scope -> apidocs -> hardening -> CODAGT-717 audit -> CODAGT-712 ACLs -> CODAGT-806 token RBAC). Split out of #27942 to keep the core cutover reviewable; each change here builds on the org-scoped routes and chat gating introduced below it. > Mux (AI agent) authored this PR on Mike's behalf. <!-- mux-attribution: model=claude-fable-5 thinking=high -->
This commit is contained in:
@@ -174,7 +174,9 @@ wins.
|
||||
| View enabled servers | Organization member |
|
||||
| OAuth2 connect and disconnect | Organization member |
|
||||
|
||||
Creating or updating a server with `auth_type` set to `user_oidc` also requires the `deployment_config:update` permission.
|
||||
|
||||
Members only see enabled servers in their own organizations. Sensitive fields
|
||||
such as API keys and client secrets are redacted in API responses.
|
||||
|
||||
The **MCP servers** settings page is part of deployment settings, so opening it in the dashboard also requires permission to edit deployment configuration.
|
||||
Organization admins without that permission can manage servers through the API.
|
||||
Creating or updating a server with `auth_type` set to `user_oidc` also requires the `deployment_config:update` permission.
|
||||
|
||||
Reference in New Issue
Block a user