Use MCP servers safely on your own computer

Day 7, 25 minutes · beginner

Goal of this lessonCheck a published MCP server before you trust it, read its tool list with the Inspector and fill in a safety check for every server you use.

Why it matters

Romy's server is harmless: you wrote every line, it reads a list in memory and writes one small file. Most servers people install are not like that. They come from someone else, they are downloaded when the host starts, and they run with your user account. The MCP docs say it plainly: a local server is an ordinary program on your computer, not a plugin in a sandbox, and it can read what you can read.

Today you look at MCP from the safe side. You learn what a local server can touch, why tool descriptions are part of the risk, and which simple habits help most. Then you check a real published server with the Inspector before you would ever trust it. At the end you have a short safety check for every server on your computer, filled in for the servers you use now.

The words you need today

  • Trust domain: the set of programs that trust each other fully. The docs say a host and its stdio servers share one trust domain: neither protects itself against the other.
  • Provenance: where a piece of software comes from and who made it.
  • Pinning: installing one exact version, such as @2.4.1, instead of whatever is newest.
  • Typosquatting: publishing a package with a name that looks like a popular one, hoping people mistype it.
  • Tool poisoning: hiding instructions for the model in a tool's name or description.
  • Sandbox or container: a closed space where a program runs with limited access to your files and network.

What a local server can touch

The local server security page lists it: a local server inherits your environment variables, can read anything your account can read, such as SSH keys and your home folder, and can connect to anywhere on the internet. The protocol does not stop any of that. Your real choices happen before the server starts: what you install, and how you run it.

The page also says the trust grows with every server you add. All servers share the same model context, so a bad server can influence how the model uses the tools of the good ones.

Five threats, in short

  1. A malicious server: a lookalike name or a taken-over project that works as promised and also steals data.
  2. An overcollecting server: an honest server that collects more than its job needs.
  3. A compromised dependency: the author is honest, but a package it uses was hacked.
  4. A poisoned tool list: tool names and descriptions are text the model reads as instructions. A server can hide orders in them, and change them later, after you approved it.
  5. A vulnerable server or bridge: honest software with a security hole.

The page is also honest about the limits: no check proves what a server will do. So the rule is to treat a third-party server as untrusted code, and give it as little access as possible.

The habits that help most

  • Keep the list short. Remove servers you do not use. Every server adds risk and also takes space in Claude's context window.
  • Prefer remote when the server needs nothing local. A server that only wraps an online service gains nothing from running on your computer.
  • Check the publisher and pin the version. The connect local servers guide pins the filesystem server as @modelcontextprotocol/server-filesystem@2.4.1. The docs note that a pin only fixes the top package, not everything it pulls in.
  • Read the tool list before you rely on a server. The Inspector lists every tool without a model in the loop. If a description contains instructions that have nothing to do with the tool's job, remove the server.
  • Give the narrowest access. One project folder, read-only where possible, never your whole home folder. Pass secrets per server, never by putting them in your shell profile for every program.
  • Isolate third-party servers in a container where you can. The page calls this the single highest-leverage step.

Your own servers too

The same care applies to what you build. On a stdio server, keep stdout for the protocol and write logs to stderr, as Romy's server does with logging. Let a tool that writes only touch the one file or folder it needs, as add_to_wishlist does. And keep the descriptions honest: they are instructions to the model.

The steps

  1. List every server your hosts use today.
  2. Inspect a published server before trusting it: list its tools with the Inspector, pinned and limited to one empty test folder.
  3. Read the tool descriptions and mark which tools only read and which can change files.
  4. Check Romy's server against the same questions.
  5. Fill in the safety check and remove what you no longer use.

Follow the steps below.

Today's actions

Ticks are not saved without an account

Do it in Claude API

Claude API

  1. Open your Claude Desktop configuration file from lesson 5 and write down every entry under mcpServers: its name, its command and where the package comes from. If you use Claude Code, claude mcp list shows its servers too.
  2. Make an empty test folder, for example mcp-test next to your quillfeather folder. Never point a test at your home folder.
  3. List the tools of the official filesystem server, pinned to the version the MCP guide uses and limited to that one folder. Replace the path with the absolute path of your test folder.
    npx -y @modelcontextprotocol/inspector --cli npx -y @modelcontextprotocol/server-filesystem@2.4.1 /ABSOLUTE/PATH/TO/mcp-test --method tools/list
  4. Read every tool name and description. Mark which only read (such as read_text_file, list_directory) and which can change files (such as write_file, edit_file, move_file). Look for any sentence that is not about the tool's own job.
  5. Create mcp-safety-check.txt, copy this check into it and fill it in once per server, including quillfeather.
    Server: 
    Where it comes from (publisher, package or my own code): 
    Version pinned?  yes / no 
    Does it need anything from my computer, or could it run remotely? 
    Folders it can reach: 
    Tools that only read: 
    Tools that can change things: 
    Any odd instruction in a tool description?  yes / no 
    Secrets it gets, and how (per server, never global): 
    Still in use?  keep / remove 
  6. Remove every server you marked remove: delete its entry from the Claude Desktop file (keep your backup), or run claude mcp remove <name> for Claude Code.

Note: Step 3 starts the filesystem server only to list its tools: nothing is read or written. The Inspector itself is run with npx, so pin it as well if you use it in scripts.

Checked on 4 December 2026 · Source: MCP docs: Local Server Security (opens in a new tab)

Create a free account to save your progress. Sign in or sign up