MCP Servers and AI Agents: The Security Risks, and How to Govern Them

What MCP is

Model Context Protocol (MCP) is a standard way to plug AI agents into tools and data. OWASP calls it “a universal interface layer, a ‘USB-C port for AI'”. An AI app such as Claude, ChatGPT, Copilot or Cursor connects to MCP servers, small programs that expose tools (search a mailbox, run a query) against your real systems, either locally or over the network.

Two facts drive the risk. The model decides which tools to call, when, and with what parameters. And the MCP authorization spec makes authorization optional. Remote servers that implement it use OAuth 2.1, the standard for granting an app limited access through scopes (for example, read mail but not send it). Local servers read credentials from the environment, usually API keys on an endpoint. If a server names no scope, clients request every scope it supports.

Why an agent becomes exploitable

Prompt injection is text that tries to give the model new instructions, typed by a user or hidden in anything the agent reads: an email, ticket, web page or tool description. It is the top item in the OWASP Top 10 for LLM Applications 2025 (LLM01), and vendors don’t claim it is solved. OpenAI says its measures “do not eliminate third-party or prompt-injection risk.”

An agent becomes exploitable when it combines three things:

  1. It reads untrusted content.
  2. It can reach private data.
  3. It can send data out or take irreversible actions.

Invariant Labs and Simon Willison have both described this combination. Governance means removing at least one of the three from every agent. An inbox assistant that reads outside email, searches SharePoint and sends mail has all three.

What has actually happened

  • GitHub MCP (May 2025). Invariant Labs showed a malicious public issue hijacking an agent into leaking private-repo data into a public pull request.
  • Asana (June 2025). A logic flaw in Asana’s MCP server exposed data across roughly 1,000 customers’ workspaces; it was offline June 5–17, per The Register and BleepingComputer.
  • Supabase (July 2025). General Analysis showed a support ticket instructing a Cursor agent with service-role database access to post a tokens table back into the ticket. Supabase’s docs now call their mitigation “not foolproof.”
  • postmark-mcp (September 2025). This malicious npm package was clean for 15 versions, then version 1.0.16 BCC’d every email to an attacker, per Postmark and Snyk.
  • EchoLeak. Zero-click email injection exfiltrated Microsoft 365 Copilot data. Tracked as CVE-2025-32711 and fixed server-side by Microsoft; MITRE ATLAS lists it as case study CS0059.
  • mcp-remote, CVE-2025-6514. JFrog reported that a malicious server could trigger command execution on the client (CVSS 9.6), fixed in 0.1.16.

Wiz reported an authentication bypass in the LiteLLM AI gateway (CVE-2026-59822), exploited in its honeypots in July 2026 and, per Wiz, added to CISA’s Known Exploited Vulnerabilities (KEV) catalog, the federal list of flaws under active attack. OX Security reported a command-injection pattern in local MCP setup across several AI products, listing CVEs for them; OX says several vendors called it by design.

Governance controls

  • Inventory and allowlist. Register every agent and MCP server with owner, data and credentials. Allow servers by exact URL or command, not by name; Claude Code’s docs warn that a server-name entry “is not a security control.” Deny by default.
  • Least-privilege scopes. Read-only by default, per-user tool enablement, narrow OAuth scopes, short-lived tokens, no shared tokens (MCP Security Best Practices). Read-only still allows reads.
  • Human approval for writes, sends and deletes. Show full parameters; no “always allow” on consequential tools (OWASP cheat sheet). Unattended agents get read-only tools.
  • Sandboxing and egress controls. Run local servers in containers. Egress is outbound network traffic: allowlist destinations and block cloud metadata and private IP ranges. The MCP spec recommends sandboxing and egress proxies.
  • Secrets handling. No tokens in mcp.json or plaintext config; use a vault or keychain, and rotate. MITRE ATLAS tracks credential theft from agent config files as technique AML.T0083.
  • Agent identities. Give autonomous agents their own governed identity, not a shared admin account. NIST’s NCCoE is working on this in its “Software and AI Agent Identity and Authorization” concept paper.
  • Logging. Send every tool call (user, agent, tool, parameters, time) to your SIEM, secrets redacted (OWASP MCP Top 10, beta, MCP08).
  • Red teaming. Test injection through your own email, tickets and documents, plus scope abuse and exfiltration paths.
  • Vendor questions. Before approving any agent platform or MCP server, ask:
    • Who maintains it? What scopes does it need, and is read-only available?
    • Does it act as the user or with a shared credential? Is tenant isolation enforced?
    • Where are tokens stored, and what is logged?
    • Do tool changes trigger re-consent?
    • How fast can we revoke one agent or connector?

Where agents are worth it, and where to hold back

Agents earn their keep on bounded internal work: searching documentation, drafting replies a person sends, triaging tickets. Keep an agent read-only when it reads outside content and also reaches internal data. Unattended agents never get write access to production, finance or permissions.

What platforms offer, and where they fall short

Controls exist; most strong ones need Enterprise tiers or added licensing. 

Microsoft Entra Agent ID gives agents their own identities, and Conditional Access for agents needs extra licensing; Microsoft notes that an agent using an API key bypasses Conditional Access. 

Copilot Studio data policies can block connectors, which also blocks tools in connected MCP servers. 

ChatGPT Enterprise disables new apps by default and lets admins limit apps to read actions; on the Business tier, apps are on by default. 

Claude limits custom connectors to admins, and Claude Code supports a managed MCP allowlist. 

Cursor Enterprise and Grok Bot Enterprise offer MCP allowlists, and Grok Bot adds network allowlists and audit logs, though Cursor states that dedicated data loss prevention hooks aren’t available.

Egnyte shows the content-platform side, where the data lives: its managed MCP server uses OAuth and limits each AI session to files the user can already open, admins choose which AI apps may connect and which MCP tools each user or group can call, and AI Safeguards policies keep selected files out of results sent to Claude, ChatGPT and other MCP clients; these controls need an Essential, Elite or Ultimate plan or the AI add-on, and classification-based policies need Ultimate. Its AI Control Center, announced October 15, 2026 is described as a way to inventory agents, show which sensitive content each can reach, and recommend narrower folder access, while AI Safeguards does the enforcing; Egnyte has not published its licensing. These controls cover only content stored in Egnyte, not what the same agent can reach in other systems. None removes prompt injection; they limit what an injected agent can do.

CMMC and CUI

On July 13, 2026, DoD (now styled the Department of War) suspended CMMC Phase II, which had been due Nov 10, 2026. Level 2 self-assessments against NIST SP 800-171 Rev 2 remain, and DFARS 252.204-7012 still applies.

CUI (Controlled Unclassified Information) is sensitive government information contractors must protect. In EUS’s reading of CMMC scoping, an agent that processes, stores or transmits CUI is in scope, with its MCP servers, and your SSP (system security plan, which documents your boundary) should show it. Our interpretation, not an official crosswalk, ties the controls above to 800-171 requirements 3.1.5 (least privilege), 3.4.8 (allowlisting), 3.3.1 (audit records) and 3.13.6 (deny by default). The safest default is to keep CUI out of commercial agents unless the whole chain sits inside your CUI boundary. NIST’s COSAiS project lists agent control overlays as planned, not yet published.

If you’re working out whether your agents change your CMMC scope, EUS, a CMMC Registered Practitioner Organization (RPO), can help you prepare.