Skip to main content

Security scanner for MCP (Model Context Protocol) servers. Detect malicious tools, data exfiltration, and supply chain risks.

Project description

MCP Scanner

Security scanner for MCP (Model Context Protocol) servers. Detect malicious tools, data exfiltration, and supply chain risks before connecting an MCP server to your AI agent.

PyPI Python 3.10+ License: MIT CI


Why MCP Scanner?

MCP servers give AI agents (Claude Code, Cursor, Copilot) direct access to tools, filesystems, and APIs. But nobody is checking if those servers are safe.

MCP Scanner analyzes:

  • MCP server config files (Claude Code, Cursor, generic)
  • Command-level risks (npx --yes, curl|bash, sudo)
  • Secret exposure in environment variables
  • Filesystem and network access patterns
  • Source code of MCP server implementations (with AgentGuard integration)

Quick Start

pip install dfx-mcp-scanner

# Scan your Claude Code MCP config
mcp-scanner

# Scan a specific config
mcp-scanner ~/.cursor/mcp.json

# JSON output
mcp-scanner .mcp.json --format json

What It Detects

Rule Severity Description
Remote code execution CRITICAL `curl
Auto-install packages HIGH npx --yes without version pinning
Privileged execution CRITICAL Server running as root/sudo
Secret exposure CRITICAL Real API keys/tokens in config env vars
Host filesystem access HIGH Server accessing /etc, /root, /proc
External network access MEDIUM Server connecting to non-localhost URLs
Excessive tool count LOW Server registering >20 tools

Supported Configs

  • Claude Code (~/.claude/claude_code_config.json)
  • Cursor (~/.cursor/mcp.json)
  • Project-level (.mcp.json)
  • Generic MCP server configs

AgentGuard Integration

When AgentGuard is installed, MCP Scanner performs deep source code analysis on MCP server implementations using all 10 OWASP ASI detection rules.

License

MIT - see LICENSE.


Built by Dockfix Labs.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dfx_mcp_scanner-0.2.0.tar.gz (10.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dfx_mcp_scanner-0.2.0-py3-none-any.whl (12.3 kB view details)

Uploaded Python 3

File details

Details for the file dfx_mcp_scanner-0.2.0.tar.gz.

File metadata

  • Download URL: dfx_mcp_scanner-0.2.0.tar.gz
  • Upload date:
  • Size: 10.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for dfx_mcp_scanner-0.2.0.tar.gz
Algorithm Hash digest
SHA256 6a87a9d6554938eb71ed41afb4f201e81d36bc3de854c5bf5dea5cb6d7949789
MD5 5cba4ab3121deb76e8376b001a731a6b
BLAKE2b-256 95fb518e64c9cf01f513ba034c854dd290a307a32685be8c178b238eb549f252

See more details on using hashes here.

Provenance

The following attestation bundles were made for dfx_mcp_scanner-0.2.0.tar.gz:

Publisher: publish.yml on dockfixlabs/mcp-scanner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file dfx_mcp_scanner-0.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for dfx_mcp_scanner-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 daeced6bc873538694f77751820973d55500da2dcac9be904d63377c7f123e77
MD5 0ce95179a6d2876e3a36cbebaf5353ee
BLAKE2b-256 d8456ac61daea6b2526f2bfe4e84fdb1be2922d90bcac79f4e1819bf7c0402f8

See more details on using hashes here.

Provenance

The following attestation bundles were made for dfx_mcp_scanner-0.2.0-py3-none-any.whl:

Publisher: publish.yml on dockfixlabs/mcp-scanner

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page