Logo vun MCP Audit

MCP Audit

Organisatioun
apisec-inc

See what your AI agents can access. Scan MCP configs for exposed secrets, shadow APIs, and AI models. Generate AI-BOMs for compliance.

Editeurapisec-inc
Repositorymcp-audit
SproochPython
Forks
45
Stären
159
Disponibel Tools
0
Transporttypstdio
LizenzMIT
Linken
  • Tools mat KI-Workflows verbannen

    MCP Audit stellt MCP-Funktioune bereit, déi vu kompatibele KI-Clienten a KI-Agente kënne benotzt ginn.

  • 0 disponibel Tools

    Kuckt Iech déi opruffbar Aktiounen hei drënner un, mat Nimm a Beschreiwungen, wa se vum Server geliwwert ginn.

  • Konfiguratioun fir ze kopéieren

    Benotzt d'Installatiounsbeispiller, fir dëse Server an Ärem bevorzugte MCP-Client ze konfiguréieren.

  • Indicateure fir Open Source

    159 Stären an 45 Forks aus dem verlinkte Repository.

MCP Audit

License: MIT Python 3.9+ GitHub release

See what your AI agents can access - before they go live.

Web App MCP Audit Web App

CLI MCP Audit CLI

Quick Start

bash
# Install
pip install -e .

# Scan your machine
mcp-audit scan

# Or try the web app (no install)
# https://apisec-inc.github.io/mcp-audit/?demo=true

What It Does

MCP Audit scans your AI development tools (Claude Desktop, Cursor, VS Code) and reveals:

  • Secrets - Exposed API keys, tokens, database passwords
  • APIs - Every endpoint your AI agents connect to
  • AI Models - Which LLMs are configured (GPT-4, Claude, Llama)
  • Risk Flags - Shell access, filesystem access, unverified sources
⚠️  2 SECRET(S) DETECTED - IMMEDIATE ACTION REQUIRED

[CRITICAL] GitHub Personal Access Token
  Location: github-tools → env.GITHUB_TOKEN
  Remediation: https://github.com/settings/tokens → Delete → Recreate

[HIGH] Database Connection String
  Location: postgres-mcp → env.DATABASE_URL
  Remediation: Rotate credentials, use secrets manager

Source-level Scanning (new in v1.1)

mcp-audit scan inventories MCP server configurations. The new mcp-audit source-scan command goes one level deeper — it reads the MCP server's own source code and flags code-level vulnerabilities the server author may have introduced.

Today it catches the "Prompt In, Shell Out" attack chain: an MCP server that pipes an LLM-controlled tool argument into a shell-spawning API (child_process.exec, util.promisify(exec), subprocess.run(shell=True), os.system, os.popen) without sanitization. An attacker controlling the LLM input can inject shell metacharacters and execute arbitrary code on the host running the MCP server.

bash
$ mcp-audit source-scan ./packages/my-mcp-server

MCP source-scan: packages/my-mcp-server
1 critical · 0 high · 1 finding(s) total

  Severity  Conf  File:Line      API                                          Snippet
  CRITICAL  high  server.js:19   util.promisify(child_process.exec) ...       const { stdout } = await execAsync(

Outputs:

  • --format table (default, human-readable)
  • --format json (CI integrations, jq pipelines)
  • --format sarif (upload to GitHub code-scanning / GitLab / similar)

Gate merges on critical findings:

bash
mcp-audit source-scan ./my-mcp --exit-code

The scanner is intentionally narrow — it only opens files that look like MCP server source (imports an MCP SDK). It won't try to find shell-injection bugs in random Node / Python code; that's not the job.

After running mcp-audit scan, you'll see a nudge in the summary suggesting source-scan against any in-house or unverified servers it discovers.

What It Finds (and Doesn't Find)

What It Finds

Scan TypeFinds
GitHub ScanMCP configs committed to repositories (mcp.json, .mcp/, claude_desktop_config.json, etc.)
Local ScanMCP configs on your machine (Claude Desktop, Cursor, VS Code, Windsurf, Zed)
Source Scan (v1.1)Code-level vulnerabilities in MCP server source (JS/TS/Python): shell-injection sinks (child_process.exec, util.promisify(exec), subprocess.run(shell=True), os.system, os.popen) called with interpolated tool arguments

What It Won't Find

Blind SpotWhy
Secrets in environment variables at runtimeWe scan config files, not running processes
Configs pulled from secrets managersVault, AWS Secrets Manager, etc. are not scanned
Dynamically generated configsConfigs created at runtime aren't in files
MCPs installed but not configuredNo config file = nothing to scan
Private repos you don't have access toGitHub scan is limited by your PAT scope
Encrypted or obfuscated secretsPattern matching won't catch encoded values
Non-standard config locationsCustom paths outside known locations

Important

A clean scan does not mean zero risk.

  • Developers may have MCPs configured on machines you haven't scanned
  • Configs may exist in repos outside your GitHub org
  • Runtime behavior may differ from static configuration

MCP Audit provides visibility, not guarantees. Use alongside runtime monitoring and security reviews.

CI/CD Integration

Fail builds on critical risks:

yaml
# .github/workflows/mcp-audit.yml
name: MCP Security Audit
on: [push, pull_request]

jobs:
  audit:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4

      - name: Install MCP Audit
        run: pip install mcp-audit

      - name: Run Security Scan
        run: mcp-audit scan --path . --format json -o mcp-report.json

      - name: Fail on Critical
        run: |
          CRITICAL=$(jq '[.mcps[] | select(.risk == "critical")] | length' mcp-report.json)
          if [ "$CRITICAL" -gt 0 ]; then
            echo "❌ Found $CRITICAL critical-risk MCPs"
            exit 1
          fi

      - name: Upload AI-BOM
        uses: actions/upload-artifact@v4
        with:
          name: ai-bom
          path: mcp-report.json

Source-level scan in CI (v1.1)

If you ship an in-house MCP server, gate merges on critical code-level findings:

yaml
# .github/workflows/mcp-source-scan.yml
name: MCP Source Scan
on: [pull_request]

jobs:
  source-scan:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - run: pip install mcp-audit

      # Fail the PR if any critical shell-injection findings are detected.
      - name: Source-scan in-house MCP server
        run: mcp-audit source-scan ./packages/my-mcp-server --exit-code

      # OR: upload findings to GitHub code-scanning instead of failing.
      - name: Source-scan -> SARIF
        run: mcp-audit source-scan ./packages/my-mcp-server --format sarif --output mcp.sarif
      - uses: github/codeql-action/upload-sarif@v3
        with:
          sarif_file: mcp.sarif

Export Formats

bash
# JSON (for CI/CD)
mcp-audit scan --format json -o report.json

# AI-BOM (CycloneDX 1.6)
mcp-audit scan --format cyclonedx -o ai-bom.json

# SARIF (GitHub Security integration)
mcp-audit scan --format sarif -o results.sarif

# CSV / Markdown
mcp-audit scan --format csv -o report.csv
mcp-audit scan --format markdown -o report.md

# PDF Report via Email
mcp-audit scan --email security@company.com

Key Features

FeatureDescription
MCP DiscoveryFind MCPs in Claude Desktop, Cursor, VS Code, Windsurf, Zed
Secrets Detection25+ secret patterns with provider-specific remediation
API InventoryDatabase, REST, SSE, SaaS, Cloud endpoints
AI Model DetectionOpenAI, Anthropic, Google, Meta, Mistral, Ollama
OWASP LLM Top 10Maps findings to OWASP LLM Top 10 (2025) framework
AI-BOM ExportCycloneDX 1.6 for supply chain compliance
SARIF OutputGitHub Security integration with OWASP tags
Registry50+ known MCPs with risk classifications

Two Ways to Use

Web AppCLI Tool
ScansGitHub repositoriesLocal machine
InstallNone (browser)Python 3.9+
Best forOrg-wide visibilityDeep local analysis
PrivacyToken stays in browser100% local

Web App: https://apisec-inc.github.io/mcp-audit/


CLI Reference

Scan Commands

bash
mcp-audit scan                    # Full inventory scan
mcp-audit scan --secrets-only     # Only secrets
mcp-audit scan --apis-only        # Only API endpoints
mcp-audit scan --models-only      # Only AI models
mcp-audit scan --verbose          # Detailed output
mcp-audit scan --path ./project   # Specific directory

Source-level Scan Commands (new in v1.1)

source-scan is a separate command from scan. scan inventories MCP configurations; source-scan reads MCP server source code and flags code-level vulnerabilities. See docs/SOURCE_SCAN.md for the full guide.

bash
mcp-audit source-scan ./my-mcp                         # Table output (default)
mcp-audit source-scan ./my-mcp --format json           # JSON for jq pipelines
mcp-audit source-scan ./my-mcp --format sarif          # SARIF for code-scanning
mcp-audit source-scan ./my-mcp --output mcp.sarif      # Write to file
mcp-audit source-scan ./my-mcp --exit-code             # CI gate (non-zero on critical)
mcp-audit source-scan ./my-mcp --explain               # Inline remediation guidance

Export Options

bash
mcp-audit scan --format json -o report.json       # JSON output
mcp-audit scan --format csv -o report.csv         # CSV output
mcp-audit scan --format markdown -o report.md     # Markdown output
mcp-audit scan --format cyclonedx -o ai-bom.json  # CycloneDX 1.6 AI-BOM
mcp-audit scan --format sarif -o results.sarif    # SARIF for GitHub Security
mcp-audit scan --email security@company.com       # PDF report via email

Registry Commands

bash
mcp-audit registry                    # List all known MCPs
mcp-audit registry --risk critical    # Filter by risk
mcp-audit registry lookup "stripe"    # Search registry

Explain a Risk Flag

bash
mcp-audit explain shell-injection-in-source   # Full remediation guidance
mcp-audit explain --list                      # All known risk flags

Risk Levels

LevelMeaningExamples
🔴 CRITICALFull system accessDatabase admin, shell access, cloud IAM
🟠 HIGHWrite accessFilesystem write, API mutations
🟡 MEDIUMRead + limited writeSaaS integrations, read-only DB
🟢 LOWRead-onlyPublic APIs, memory storage

Detected Secrets

SeverityTypes
🔴 CriticalAWS Keys, GitHub PATs, Stripe Live Keys, DB Credentials
🟠 HighSlack Tokens, OpenAI Keys, Anthropic Keys, SendGrid
🟡 MediumWebhooks, Generic API Keys

Privacy

  • Web App: GitHub token never leaves your browser
  • CLI: Runs 100% locally, no telemetry
  • PDF Reports: Only summary data sent (no secrets)

Installation

Option 1: Python (pip)

bash
# Clone and install
git clone https://github.com/apisec-inc/mcp-audit.git
cd mcp-audit
pip install -e .

# Verify
mcp-audit --help

Requires Python 3.9+

Option 2: Docker

bash
# Build image
docker build -t mcp-audit .

# Scan current directory
docker run -v $(pwd):/scan mcp-audit scan

# Scan with JSON output
docker run -v $(pwd):/scan mcp-audit scan --format json -o /scan/report.json

Verify Download Integrity

All MCP Audit releases include SHA256 checksums.

Verify CLI Download

bash
# Download the checksum file
curl -O https://github.com/apisec-inc/mcp-audit/releases/latest/download/CHECKSUMS.txt

# Verify the zip file
shasum -a 256 -c CHECKSUMS.txt --ignore-missing

Expected output:

mcp-audit-cli.zip: OK

Current Release Checksum

FileSHA256
mcp-audit-cli.zip4917a451742038355265b0d9a74c0bb2b3a5ada28798ce3dd43238a8defcaa73

Full checksums: CHECKSUMS.txt


Documentation

License

MIT - see LICENSE


Built by APIsec

MCP Audit MCP mat verschiddene KI-Modeller benotzen

TypingMind verbënnt MCP-Tools um Niveau vum Aarbechtsberäich. Soubal MCP Audit verbonnen ass, kënnt Dir et mat verschiddene KI-Modeller an TypingMind benotzen, amplaz et fir all Modell separat anzeriichten. Dës MCP-Integratioun leeft lokal iwwer den TypingMind-MCP-Connector op Ärem Apparat.

Ariichtungsuleedung fir de lokale Connector ze benotzen

Benotzt dës Optioun, wann den MCP-Server Zougrëff op lokal Fichieren, Appen oder privat Ressourcen op Ärem Computer brauch.

1

D'MCP-Astellungen opmaachen

Gitt an TypingMind op „Astellungen“, „Erweidert Astellungen“, dann op „Model Context Protocol“ a wielt „Connector ariichten“.

  1. Maacht TypingMind an Ärem Browser op.
  2. Klickt op d'Astellungssymbol.
  3. Gitt op „Erweidert Astellungen“.
  4. Maacht d'Sektioun „Model Context Protocol“ op.
  5. Klickt op „Connector ariichten“ a wielt „Dësen Apparat“.
Ariichtungsbildschierm vum TypingMind-MCP-Connector mat „Dësen Apparat“ ausgewielt
2

De Connector-Befeel ausféieren

Wielt „Dësen Apparat“, kopéiert de Befeel aus TypingMind a féiert en am Terminal aus. Loosst de Prozess lafen, wärend Dir MCP benotzt.

  1. Kopéiert den Ariichtungsbefeel, deen TypingMind uweist.
  2. Maacht Terminal op macOS oder Windows Terminal op Windows op.
  3. Pescht de Befeel an a féiert en aus.
  4. Bestätegt d'Installatioun vum Package, wann den Terminal Iech freet, ob Dir weiderfuere wëllt.
  5. Loosst den Terminal an de Prozess doranner lafen, wärend Dir MCP-Tools benotzt.
3

MCP Audit als Server derbäisetzen

Wann de Connector-Status „Prett“ ass, klickt op „Serveren änneren“ a pescht d'MCP-Serverkonfiguratioun an.

  1. Waart, bis de Connector-Status „Prett“ weist.
  2. Klickt op „Serveren änneren“.
  3. Pescht d'MCP-Serverkonfiguratioun vu MCP Audit an.
  4. Späichert d'Serverlëscht.
  5. Aktualiséiert, wann Dir kontrolléiere wëllt, ob de Connector nach ëmmer prett ass.
MCP-Astellunge vun TypingMind mat aktivem Server an dem Knäppchen „Serveren änneren“
{
  "mcpServers": {
    "mcp-audit": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

D'Verbindung mat verschiddene Modeller benotzen

Späichert d'Serverlëscht, maacht „Plugins“ op an aktivéiert d'MCP-Tools vu MCP Audit. Wielt dann e belibegen ënnerstëtzte KI-Modell an TypingMind a benotzt d'Tools am Chat oder weist se engem KI-Agent zou.

  1. Maacht d'Säit „Plugins“ an TypingMind op.
  2. Aktivéiert d'MCP-Tools vu MCP Audit.
  3. Start e Chat a wielt de KI-Modell, deen Dir benotze wëllt.
  4. Benotzt d'MCP-Tools am Chat oder weist se engem KI-Agent zou.
  5. Wiesselt bei Bedarf op en anere KI-Modell, ouni MCP nei ze verbannen.
TypingMind-Chat mat aktivéierte MCP-Tools an engem ausgewielte KI-Modell
Hëlleft Dir mir bei dëser Aufgab mat MCP Audit?
MCP Audit
Jo. Ech hunn et gelies.
Dat hunn ech mat MCP Audit fonnt.

Heefeg gestallte Froen

Fir wat gëtt de MCP-Server MCP Audit benotzt?

MCP Audit ass e MCP-Server, deen et kompatibele KI-Clienten erlaabt, sech mat externen Tools a Kontext ze verbannen. An TypingMind kënnt Dir dëse MCP-Server eemol derbäisetzen a seng Tools an Ärem KI-Aarbechtsberäich zur Verfügung stellen.

Kann ech MCP Audit MCP mat méi KI-Modeller an TypingMind benotzen?

Jo. TypingMind verbënnt MCP-Tools um Niveau vum Aarbechtsberäich. Sou kënnt Dir MCP Audit mat verschiddene KI-Modeller wéi Claude, ChatGPT, Gemini oder anere Modeller benotzen, déi Dir an TypingMind konfiguréiert hutt, ouni de MCP-Server fir all Modell separat anzeriichten.

Firwat MCP Audit MCP mat TypingMind benotzen?

TypingMind ass eng vun de beschte Benotzeruewerfläche fir LLM-Chat, well et méi KI-Modeller, Prompts, Plugins, KI-Agenten, API-Schlësselen a MCP-Tools an engem Aarbechtsberäich zesummebréngt. Wann MCP Audit verbonnen ass, kënnt Dir seng MCP-Tools mat Äre bevorzugte Modeller benotzen a gläichzäiteg Är Chataarbecht an TypingMind organiséieren.

Wéi verbannen ech MCP Audit MCP mat TypingMind?

MCP Audit leeft iwwer de lokale MCP-Connector vun TypingMind. Dat eegent sech am beschten, wann de MCP-Server Zougrëff op lokal Fichieren, Desktop-Apps, Kommandozeilen-Tools oder privat Ressourcen op Ärem Computer brauch.

Wéi eng Tools stellt MCP Audit MCP an TypingMind zur Verfügung?

MCP Audit stellt MCP-Funktiounen zur Verfügung, déi Dir op der Plugins-Säit vun TypingMind aktivéiere kënnt, fir se am Chat ze benotzen oder KI-Agenten zouzeweisen.

Muss ech meng API-Schlëssele mat TypingMind deelen, fir MCP Audit MCP ze benotzen?

Nee. TypingMind setzt op lokal Veraarbechtung a léisst Iech d'Kontroll iwwer Är Modellubidder, API-Schlësselen, Prompts a MCP-Konfiguratioun. Wann MCP Audit eng Authentifizéierung verlaangt, setzt déi néideg Headeren, OAuth-Astellungen oder lokal Konfiguratioun fir dee MCP-Server derbäi, wann Dir d'Verbindung erstallt.

Änlech MCP-Serveren

All weisen

Elo Ären eegene KI-Workspace ariichten

Abonnéiert Iech op eisen Newsletter, fir iwwer nei Funktiounen an zukünfteg Gewënnspiller informéiert ze ginn 👇