MCP server configuration for Copilot
Why Tier 1
Decides which tools the agent uses without asking, which servers it talks to, and which COPILOT_MCP_ secrets each server receives. Pointing a server at an attacker's URL sends it those secrets and every tool call.
JSON in the repository's Copilot settings that adds MCP servers, with a tools allow list and environment values, for Copilot cloud agent and Copilot code review. Repository administrators set it. The GitHub and Playwright MCP servers are on by default.
Available on: Free (with a Copilot plan), Team (with a Copilot plan), Enterprise Cloud, EMU. Source
Attack path
Copilot uses configured MCP tools on its own and never asks before calling them. MCP servers run outside the agent firewall. With tools set to all and a write-capable token, a prompt-injected agent can do whatever the server allows; a changed server URL or command receives the secrets mapped to it.
Mitigations
- Decide which AI coding agents and MCP servers may work on the organization's repositories
- Allow list specific read-only tools instead of all
- Review changes to the MCP configuration like workflow changes
- Pass each server only the COPILOT_MCP_ secrets it needs
Detect
Nothing in the organization or enterprise audit log shows this. Review it on a schedule instead.