# MCP Server Security Check

> Audit MCP servers for prompt injection, risky parameters, and security vulnerabilities using mcp-toolcheck.

MCP Server Security Check is a free AI agent skill on Agensi by César Urbiña, in Security. It loads into your AI agent through the Agensi MCP server, always in its latest approved version.

- Price: Free
- Creator: [César Urbiña](https://www.agensi.io/creators/cessadev)
- Category: [Security](https://www.agensi.io/skills/security)
- Uses: 2
- Version: 1.0
- Last updated: 2026-10-17
- Security: scan passed (2026-10-16); every new listing is also reviewed by a person
- Listing: https://www.agensi.io/skills/mcp-server-security-check
- Tags: security, llm-ops, json-schema, python, tool-poisoning, prompt-injection, audit

## About this skill

Connecting an untrusted Model Context Protocol (MCP) server to your agent exposes your system to prompt injection and unauthorized file or network access. This skill audits MCP tool definitions to identify risky parameters and hidden instructions before you connect them.

### What it does
- **Scans tool definitions** by inspecting names, descriptions, and input schemas for common vulnerabilities.
- **Detects prompt injection** to find hidden instructions in tool descriptions designed to steer the model.
- **Identifies risky parameters** like raw shell commands, file paths, URLs, and SQL injection vectors.
- **Flags credential requests** where a tool inappropriately asks for API keys or secrets in plain text.
- **Provides remediation** by mapping every finding to a specific fix based on established security rules.

### How it works
1. **Environment check** verifying `mcp-toolcheck` is installed or requesting permission to install the pinned version via `uv` or `pip`.
2. **Definition ingestion** where you provide the server's tool list as a JSON file or command.
3. **Automated scanning** using the `mcp-toolcheck scan` command with the `--tools-file` flag for safe, execution-free auditing.
4. **Result interpretation** mapping rule IDs (MCP001-MCP010) to plain-language risk assessments and fixes.

### Frameworks & tools
This skill uses the open-source `mcp-toolcheck` command-line utility. It requires Python 3.10 or newer and can be run via `uv` or `pip`.

### Why this beats prompting it yourself
Standard LLMs often miss subtle prompt injections hidden in technical schemas or fail to recognize the security implications of specific JSON-schema patterns. This tool uses a specialized heuristic engine and a formal ruleset to ensure consistent detection of known MCP attack vectors.

### Use cases
- **Vetting third-party servers** before adding them to your agent's configuration.
- **Hardening your own MCP server** by identifying risky parameter designs during development.
- **Compliance auditing** to ensure internal tools meet security standards for LLM interaction.

### Known limitations
This skill uses heuristics that may produce false positives or negatives. It only inspects declared metadata, not the server's source code or runtime behavior. It cannot detect manipulation worded without known trigger phrases.

Uses the open-source mcp-toolcheck scanner (MIT, no API keys, no telemetry) and explains each finding.

**Source:** https://github.com/cessadev/mcp-toolcheck

## Requires

- Git
- uv (Python tool runner)
- Python

## How to use this skill

1. Connect your AI agent to Agensi once: add the MCP server https://mcp.agensi.io/mcp/auth and sign in with your Agensi account (OAuth, no API key). Steps for Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and other agents: https://www.agensi.io/docs/mcp-setup
2. Ask your agent: "Use the MCP Server Security Check skill from Agensi" and describe your task.
3. Your agent loads the skill from Agensi when it needs it. Nothing is downloaded.

## Frequently asked questions

### How does this skill protect my agent from malicious MCP servers?

This skill audits Model Context Protocol (MCP) server definitions to detect prompt injections, risky parameters (like shell command access), and insecure input schemas before you connect them to your agent. It acts as a security gatekeeper to prevent third-party tools from compromising your local environment.

### Does the MCP server need to be running or 'live' for the security check to work?

No, this skill performs static analysis on tool metadata and schemas, meaning it never needs to execute the server's code to find vulnerabilities. This allows you to safely inspect potentially dangerous servers in an isolated, execution-free environment.

### What are the technical requirements for running the mcp-server-security-check?

This skill requires Python 3.10+ and the `mcp-toolcheck` utility. It is compatible with any AI agent or platform that supports MCP integration, such as Claude Desktop, provided the agent can access the local filesystem to read server definitions.

### Does the audit provide actionable advice on how to fix the security issues it finds?

Yes, the skill maps every finding to specific Rule IDs (MCP001-MCP010), providing clear remediation steps and plain-language explanations of why a specific parameter or description was flagged.

### Can this skill detect every possible security threat in an MCP server?

While highly effective at catching known patterns like SQL injection vectors and hidden instructions, it cannot detect runtime behaviors or source code vulnerabilities. It is designed to audit what the tool *claims* to do in its metadata, not its internal logic.

---

Source: [Agensi](https://www.agensi.io), the marketplace of skills for AI agents. Any MCP-compatible agent (Claude, ChatGPT, Claude Code, Codex, Cursor, VS Code and more) connects at https://mcp.agensi.io/mcp/auth and signs in with an Agensi account; setup for every agent: https://www.agensi.io/docs/mcp-setup. Append .md to any skill, guide or docs address on agensi.io for its markdown version.
