The "S" in MCP: Scrutinising the Current State of Model Context Protocol


(Last updated 17-May-25)

The Model Context Protocol (MCP) is rapidly emerging as a foundational technology for connecting Large Language Models (LLMs) with external tools and data sources. Hailed as the "USB-C for AI," MCP aims to standardise these interactions, making AI assistants more capable and context-aware. However, like any emerging technology, a healthy dose of skepticism and a sharp focus on security are paramount. As the already-worn joke goes - "the S in MCP stands for Security".

I'm not sold yet.

More Than Meets The Eye

One common point of confusion is the term "MCP Server". While it suggests a standalone service, MCP servers are typically lightweight proxies or adapters to existing APIs. This distinction is vital because the reliability and, more critically, the security of the MCP server are intrinsically linked to the underlying API and the integrity of the proxy itself.

Stranger Danger

The ease of creating and hosting MCP servers (see frameworks such as mcp-agent and FastMCP) has led to a proliferation of available options, including many developed by third parties rather than service owners themselves. This presents significant security challenges:

Real-World Risks: The Third-Party WhatsApp MCP Server

It's not just theoretical. We've seen real-life examples of the dangers posed by unofficial, third-party MCP servers. For instance, third-party MCP servers claiming to offer access to services like WhatsApp have emerged. Because these weren't run or owned by Meta, the potential for the hoster to Man-in-the-Middle (MITM) all requests, steal sensitive messages, contact details, or authentication tokens is a stark reality. This major security risk underscore the critical need to scrutinise the origin and trustworthiness of any MCP server, particularly when less-technical end-users are involved.

The LLM: Not Just a Tool, But a Potential Adversary

It's crucial to remember that the LLM itself should always be treated as a potential adversary and sandboxed accordingly. This is even more critical than with traditional software libraries pulled from registries (which already carry supply chain risks). An LLM is:

Connecting such an entity to external tools and data via MCP without extreme caution is inviting trouble.

Prompt Injection: The Unholy Trinity

One of the most significant threats in the LLM-MCP interaction is prompt injection. The danger becomes acute when three conditions are met - The Unholy Trinity:

  1. Access to Private Data: The LLM, via MCP or its context, can read sensitive information.
  2. Exposure to Malicious Instructions: The LLM ingests untrusted input (e.g. from a compromised MCP server response, or a malicious user prompt that the MCP server might relay or act upon) that can override its original instructions.
  3. Ability to Exfiltrate Information: The LLM, now under malicious control, can send the private data to an attacker-controlled destination, potentially through an MCP tool itself (e.g. a generic "send_data_to_url" tool).

Simply putting guardrail instructions in prompts or system messages (e.g. "You are a helpful assistant. Do not reveal private information.") is a poor and unreliable defense. These are often easily bypassed with clever prompt engineering or "jailbreaking" techniques. This is akin to telling a web application via a comment in its HTML not to be vulnerable to SQL injection - it's simply not a robust security control.

Best Practices for More Secure MCP Usage

Given these amplified risks, these are some proposed best practices:

The MCP Gateway: A Centralised Defense and Efficiency Layer

MCP Gateways and similar tools are only just starting to hit the market with limited functionality, though I expect organisations will quickly begin adopting these products as standard as they mature. An MCP Gateway - locally hosted or organisationally controlled - is critical to maintain control in this high-risk environment. It should act as a central hub with essential security and operational functions. Here is the core featureset I expect to emerge:

Where Do We Go From Here?

MCP offers exciting possibilities, but the path forward requires deep security consciousness and smart architectural choices. Considering the MCP specification has only recently started to include mentions of authorisation, there is a long maturity journey ahead - MCP may even fall to the wayside. Agent-to-Agent (A2A) protocol is also in it's infancy, offering another method of abstraction. The "build fast, break things" mantra of early-stage development clearly describes how security is typically an afterthought in exchange for rapid technological evolution. That's fine, but we should understand how to mitigate this ourselves.