AI Scanner

io.github.Aakashbhardwaj27由 GitHub 帳號 Aakashbhardwaj27 發布v1.0.6更新於 Oct 24, 2026

Scan codebases for LLM/AI SDK usage, exposed API tokens, and hardcoded secrets.

已驗證STDIO僅桌面開發者工具安全與監控

概覽

AI 產生的概覽

本機 MCP 伺服器,讓助理掃描程式碼庫中的 LLM/AI SDK 使用情形、外洩的 API 權杖與硬編碼密鑰。

可以做什麼
  • 對指定目錄執行完整掃描,偵測 LLM SDK、AI 框架、外洩權杖與硬編碼密鑰並標示嚴重程度
  • 執行僅針對憑證外洩的通過/失敗安全檢查,適合提交前檢查
  • 產出 AI 技術棧清單,列出所用 SDK、框架、模型與 API 端點,不做密鑰偵測
  • 可透過僅 AI 模式、是否包含 .env 檔案、端點與模型偵測等選項調整掃描範圍
適用情境
適合在提交或推送程式碼前讓助理稽核專案、檢查是否有外洩的 API 金鑰等憑證,或了解程式碼庫使用了哪些 AI SDK、框架與模型。
執行需求
透過 npx 從 npm 套件 ai-scanner-mcp 以本機程序執行,需要 Node.js 以及 Claude Code、Claude Desktop、Cursor 或 Windsurf 等本機 MCP 用戶端。未宣告需要帳號、API 金鑰或環境變數。
安裝前請注意
啟用相關選項時掃描會讀取 .env 等含憑證的檔案,掃描結果可能在對話中揭露密鑰內容;將掃描輸出傳送到其他地方前請先確認內容。掃描為唯讀操作,但會涵蓋你指定的路徑。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 AI Scanner,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

[ai-scanner logo]

ai-scanner-mcp

MCP server for ai-scanner - let AI agents scan codebases for LLM usage, AI frameworks, and exposed secrets.

[License: MIT] [Node.js] [MCP]

An MCP server that exposes ai-scanner as tools for AI agents. Works with Claude Code, Claude Desktop, Cursor, Windsurf, and any MCP-compatible client.

Tools

ToolDescription
scan_directoryFull scan — LLM SDKs, AI frameworks, exposed tokens, and hardcoded secrets with severity levels
check_secretsSecurity check — pass/fail scan for exposed credentials only. Perfect for pre-commit checks
ai_inventoryAI stack overview — which SDKs, frameworks, models, and API endpoints are used (no secret detection)

Setup

Claude Code

bash
claude mcp add ai-scanner npx ai-scanner-mcp

Claude Desktop

Add to your claude_desktop_config.json:

json
{  "mcpServers": {    "ai-scanner": {      "command": "npx",      "args": ["ai-scanner-mcp"]    }  }}

Config file location:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json

Cursor

Add to .cursor/mcp.json in your project:

json
{  "mcpServers": {    "ai-scanner": {      "command": "npx",      "args": ["ai-scanner-mcp"]    }  }}

Windsurf

Add to ~/.windsurf/mcp.json:

json
{  "mcpServers": {    "ai-scanner": {      "command": "npx",      "args": ["ai-scanner-mcp"]    }  }}

Example Usage

Once connected, you can ask your AI agent:

  • "Scan this project for any exposed API keys"
  • "Check if there are any hardcoded secrets before I commit"
  • "What AI SDKs and frameworks does this codebase use?"
  • "Run a security scan on ./src and tell me if it's safe to push"
  • "Give me an AI inventory of this project"

Tool Details

scan_directory

Full scan with all detection categories. Parameters:

ParameterTypeDefaultDescription
directorystringrequiredPath to scan
ai_onlybooleanfalseSkip generic secrets (Stripe, GitHub, etc.)
scan_envbooleanfalseInclude .env files
include_endpointsbooleantrueDetect LLM API endpoint URLs
include_modelsbooleantrueDetect model name references

check_secrets

Security-focused pass/fail check. Parameters:

ParameterTypeDefaultDescription
directorystringrequiredPath to scan
ai_onlybooleanfalseOnly check AI tokens
scan_envbooleanfalseInclude .env files

ai_inventory

AI stack awareness (no secret detection). Parameters:

ParameterTypeDefaultDescription
directorystringrequiredPath to scan

Detection Coverage

  • AI Tokens (20+) — OpenAI, Anthropic, Google, AWS, HuggingFace, Groq, Replicate, and more
  • Generic Secrets (59) — Stripe, Twilio, GitHub, Slack, Discord, database URIs, private keys, JWTs
  • LLM SDKs (23) — OpenAI, Anthropic, Google Gemini, LiteLLM, AWS Bedrock, and more
  • AI Frameworks (24) — LangChain, LlamaIndex, CrewAI, AutoGen, DSPy, Vercel AI SDK, and more
  • 145 total detection patterns

License

MIT

來源:README.md,提交 d1be69e

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v1.0.6最新Sep 16, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分