What is a malicious MCP server?

What one can do, how it reaches you, what the official registry looks like — and six checks to do by hand before you add one.

The short answer. An MCP server is a program your AI agent calls for tools. A malicious one is a server whose code, launch command or remote endpoint does something other than what its listing says — and your agent calls it with your permissions and your credentials. Nobody can tell you a server is safe. You can tell, in a few minutes, whether it is trustworthy enough to add.

What an MCP server can do

A local server is a process on your machine. The launch line in your agent's settings — npx, uvx, docker run or a binary — runs every time a session starts, as you, with your files, your SSH keys and your cloud credentials in reach. A launch line that downloads something and pipes it into a shell runs whatever that URL serves that day.

A remote server is an endpoint someone else runs. It receives every tool call your agent makes to it, and any token you put in its headers or environment. There is no code for you to read, only a host to trust.

Either kind writes text your model reads. Tool names, descriptions and results go into the agent's context. A server can put instructions there that you never see on screen and the agent may follow.

How a malicious one reaches you

A fake server, found by an assistant. In the FakeGit campaign Island documented in July 2026, over 800 repositories posed as AI Skills or MCP servers, and more than 600 listings for them were placed in public MCP and Skill directories — LobeHub, Glama, MCP.so and MCP Market. Assistants that search those directories surfaced them; AgentBaiting is Island's name for that technique. The payload was not in the source tree: it was a ZIP attached to a release, and the install steps pointed at it.

A registry that takes what it is given. OX Security submitted a proof-of-concept malicious MCP server to eleven public registries; nine accepted it without review (Cloud Security Alliance, April 2026).

A launch line that fetches and runs. A repository can check in an MCP settings file whose command downloads and executes something the moment a trusting editor or agent opens the folder — the shape check C20 looks for.

A package that changes after you added it. A launch line with no version — npx -y @scope/server — starts whatever the latest release is, every session. What you read last month is not necessarily what runs today.

What the official registry looks like

We enumerated every record in the official Model Context Protocol registry on 5–6 October 2026 and counted what is there. The census has the full distribution and the method; the figures that matter for this question are below. It names no servers and no publishers, and neither does this page.

What the census countedServersShare
Servers in the registry (latest version of each)39,653100%
Declare no source repository at all10,69427.0%
Offer a remote URL only — nothing to inspect22,87657.7%
Offer neither a package nor a remote4321.3%

Publication is concentrated: the median namespace publishes one server, and the most servers backed by a single repository within one namespace is 375. A monorepo of connectors is an ordinary pattern, and bulk registration is not a vulnerability — but the registry's own metadata cannot tell 375 independent servers from one repository registered 375 times, and neither can a person browsing it.

One more result, because it is the opposite of what we expected: none of the 7,600 FakeGit repositories, and none of their accounts, appear among the 23,309 repositories behind registry servers. The campaign's fake MCP servers went through third-party directories and chat surfaces, not the protocol's own registry. A registry listing is therefore not a sign of malice — and it is not a review either.

Six checks, by hand

The step-by-step version, with what to do in Claude Code itself, is how to vet an MCP server before connecting it.

1. Does it declare a source repository? No repository means no code to read and no history to judge. Treat it as a remote you are trusting on the listing's word.

2. Who owns that repository, and since when? Read the owner's Joined date before the README. An account and a repository created in the same month is the FakeGit shape.

3. Read the launch line. A curl or wget piped into sh, bash or node is the pre-trust execution class. Prefer a package you can name and pin.

4. Pin the version. npx -y @scope/server@1.2.3 or uvx server==1.2.3, so a new release cannot change what starts.

5. For a remote: is the host the vendor's own? Match the URL against the vendor's own website and documentation before you give it a token. A lookalike domain with a working endpoint is cheap.

6. Do not run a README's install steps verbatim. A ZIP link in the install instructions of a supposed MCP server was the delivery path in 211 FakeGit repositories.

What RepoGates does with the same questions

For an MCP server, the instrument RepoGates has today is the repository behind it, which the census shows reaches at most 72.9% of the registry. Within that:

What it covers, and what it cannot

A listing in the official MCP registry is assessed as its own thing since 1 November 2026, through ten checks of its own — its status, namespace verification, the declared repository, the package it launches and the secrets it asks for (the threat model and the measurement) — through the MCP server and the Claude Code plugin, not in the browser. A remote-only server has no code in the picture at all. Nothing RepoGates does observes what a server does once it runs.

RepoGates gates browser downloads — Download ZIP, release assets, Save-Link-As. It does not see git clone, package managers or curl — outside Claude Code with the RepoGates plugin, whose hook refuses a clone or install that names a blocked repository on the command line, before it runs. The hook sees Bash tool calls in that one client and nothing else: it reads the command a claude mcp add line will start, but it does not see a server added by editing a settings file or through the /mcp menu, or a call an agent makes to a remote MCP server. Edit and Write are read for one thing only — an API key about to be saved — checked on the machine and never sent; that guard asks, it never denies. The MCP server is a check an agent can be told to call; an agent that never calls it is not stopped.

Questions

Is a server in the official MCP registry safe? A listing is not a review. In our census of 5–6 October 2026, 27.0% of the registry's 39,653 servers declared no source repository and 57.7% were remote-only, so there was no code to read. Publishing there says who registered a name, not what the server does.

Can RepoGates tell me an MCP server is safe? No, and nothing honest can. It scores the repository behind a server, flags a launch line that fetches and runs something, and records when an MCP directory sent you to a repository. It does not observe what a server does once it runs, and a listing in the official registry is assessed through ten checks of its own.

Does the Claude Code plugin see claude mcp add? Yes, as a Bash tool call in Claude Code: claude mcp add srv -- npx -y some-package is read as if npx -y some-package had been typed, and a remote server added that way is asked about. It does not see a server added by editing a settings file or through the /mcp menu.

Connect your AI agents The registry census

The repository checks, the check-up and the plugin run on the paid plans; C22 runs in the browser extension. Numbers on this page: the RepoGates census of the official MCP registry, 5–6 October 2026; Island, 20 July 2026; BleepingComputer, 21 July 2026; Cloud Security Alliance on OX Security's registry submissions, April 2026 — linked from the AgentBaiting page.