Virustotal

io.github.w0h1v由 GitHub 帳號 w0h1v 發布v1.0.38更新於 Nov 5, 2026

MCP server for querying VirusTotal API with comprehensive security analysis tools.

概覽

AI 產生的概覽

透過 VirusTotal v3 API 讓助理查詢檔案、URL、IP 與網域的安全報告,並沿威脅關聯關係繼續追查。

可以做什麼
  • 查詢檔案、URL、IP 與網域的綜合報告,並附帶關鍵關聯資料
  • 依關係類型分頁取得上述各類指標的完整關聯清單
  • 以 IOC、自由文字或 VTI 風格修飾符檢索 VirusTotal 語料庫
  • 取得某個檔案雜湊合併後的沙箱行為摘要
  • 依 ID 取得威脅組織、惡意軟體家族、攻擊活動或情報報告集合
適用情境
適合在安全分析中快速研判指標:查看雜湊、URL、IP 或網域的偵測結果,追蹤其聯絡的網域、釋放的檔案,或依屬性搜尋樣本。適合已持有 VirusTotal API 金鑰、希望在聊天用戶端內直接查詢的分析人員。
執行需求
需要 Node.js 20 或更新版本,以及透過 VIRUSTOTAL_API_KEY 環境變數提供的 VirusTotal API 金鑰。預設以 stdio 在本機執行;可選的 HTTP 串流模式使用 MCP_TRANSPORT、MCP_HOST、MCP_PORT 與 MCP_ENDPOINT。需要能連線至 VirusTotal API 的網路。
安裝前請注意
查詢會把你的指標傳送給 VirusTotal,快取未命中時掃描 URL 會將該 URL 提交分析。可選的 HTTP 傳輸沒有身分驗證,任何能連上該連接埠的人都能消耗你的 API 配額,應僅綁定本機或置於具驗證的反向代理之後。公開 API 層級每分鐘僅允許 4 次請求。

安裝

在 SourceWeft 中

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

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

其他 MCP 客戶端

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

README

[mcp-virustotal: threat intelligence for AI agents]

[npm version] [CI] [License: MIT] [Node 20 or newer] [MCP Registry]

Quickstart · Tools · HTTP · Security · Troubleshooting · Docs

mcp-virustotal is an MCP server that gives AI agents access to the VirusTotal v3 API. Hand your agent a hash, URL, IP or domain and get back the detection report plus the relationships an analyst would pivot on: contacted hosts, dropped files, resolutions, threat actors.

[!NOTE] Independent project, not affiliated with VirusTotal or Google. You need your own VirusTotal API key.

Highlights

  • Reports with relationships. File, URL, IP and domain reports fetch key relationships in one batched ?relationships= call to save quota.
  • Cache first. get_url_report returns the cached VirusTotal report and only submits a scan on a cache miss.
  • Pivot tools. Corpus search with VTI-style modifiers (type:peexe positives:5+), merged sandbox behaviour summaries, and threat-actor and malware-family collections.
  • Full relationship paging. 100+ relationship types across files, URLs, IPs and domains, with cursor pagination.
  • Two transports. stdio for desktop clients, HTTP streaming for a shared service.
  • Tested. Unit tests for the formatters and API layer run in CI on Node 20, 22 and 24.

How it works

mermaid
flowchart LR    A["AI agent<br/>(Claude, Codex, Gemini, VS Code)"] -->|"MCP over stdio or HTTP"| S["mcp-virustotal"]    S -->|"validate input,<br/>HTTPS + API key"| V["VirusTotal v3 API"]    V -->|"JSON"| S    S -->|"formatted report text"| A

Quickstart

Requirements: Node.js 20 or newer and a VirusTotal API key.

sh
# Claude Codeclaude mcp add --transport stdio --env VIRUSTOTAL_API_KEY=your-key virustotal -- npx -y @burtthecoder/mcp-virustotal
# Codex CLIcodex mcp add virustotal --env VIRUSTOTAL_API_KEY=your-key -- npx -y @burtthecoder/mcp-virustotal
# Gemini CLIgemini mcp add -e VIRUSTOTAL_API_KEY=your-key virustotal npx -y @burtthecoder/mcp-virustotal

For Claude Desktop, VS Code and running from source, see Connect a client.

Then ask your agent: "Look up the SHA-256 275a021bbfb6489e54d471899f7db9d1663fc695ec2fe2a2c4538aabf651fd0f (the EICAR test file) and show what it drops and contacts."

Tools

Eleven tools. Full parameters and relationship lists are in the tool reference.

GroupTools
Reports (with relationships)get_file_report, get_url_report, get_ip_report, get_domain_report
Relationship pagingget_file_relationship, get_url_relationship, get_ip_relationship, get_domain_relationship
Search and pivotsearch_vt, get_file_behaviour_summary, get_collection

HTTP streaming transport

stdio is the default. Set MCP_TRANSPORT=httpStream to run a standalone HTTP service:

sh
MCP_TRANSPORT=httpStream MCP_PORT=3000 VIRUSTOTAL_API_KEY=your-key node build/index.js
sh
docker build -t mcp-virustotal .docker run -p 127.0.0.1:3000:3000 -e VIRUSTOTAL_API_KEY=your-key -e MCP_TRANSPORT=httpStream mcp-virustotal

A health check is served at /health.

Environment variables

VariableDefaultDescription
VIRUSTOTAL_API_KEY(required)Your VirusTotal API key
MCP_TRANSPORTstdiostdio or httpStream
MCP_HOSTlocalhostBind address (httpStream only). The Docker image sets 0.0.0.0
MCP_PORT3000HTTP port (httpStream only)
MCP_ENDPOINT/mcpHTTP endpoint path (httpStream only)

Security

[!WARNING] The HTTP transport has no authentication. Keep the port on localhost or behind an authenticating reverse proxy, or anyone who can reach it can spend your API quota.

  • Tool arguments are validated with zod schemas before any request is built.
  • The API key is read from the environment and sent only to VirusTotal.
  • Lookups send your indicators to VirusTotal. A URL scan on a cache miss submits that URL for analysis.

Report vulnerabilities privately; see SECURITY.md.

Troubleshooting

  • Wrong API key: the key is usually 64 characters with no spaces or quotes. Restart the client after changing config.
  • 429 errors: the public tier allows 4 requests per minute.
  • Logs: logs/mcp-virustotal-server.log in the package directory.

More in the troubleshooting guide.

Development

sh
git clone https://github.com/w0h1v/mcp-virustotal && cd mcp-virustotalnpm cinpm test                                  # build + unit tests, no key or networkVIRUSTOTAL_API_KEY=your-key npm run smoke # all 11 tools against the real API

The smoke test paces calls at 20 s for the public-tier limit and isn't suited to free tiers reduced to a few lookups a day. See CONTRIBUTING.md and the changelog.

License

MIT. See LICENSE.

來源:README.md,提交 470fc38

工具

11

get_url_report

Get a comprehensive URL analysis report including security scan results and key relationships (communicating files, contacted domains/IPs, downloaded files, redirects, threat actors). Returns the cached VirusTotal report when available, or submits the URL for scanning and waits for results.

輸入參數url必填

get_url_relationship

Query a specific relationship type for a URL with pagination support. Choose from 22 relationship types including communicating files, contacted domains/IPs, downloaded files, redirects, referrers, threat actors, and collections. Useful for paging through the full list when the summary in get_url_report is truncated.

輸入參數url必填limitcursorrelationship必填

get_file_report

Get a comprehensive file analysis report using its hash (MD5/SHA-1/SHA-256). Includes detection results, file properties, and key relationships (behaviors, dropped files, network connections, embedded content, threat actors). Returns both the basic analysis and automatically fetched relationship data.

輸入參數hash必填

get_file_relationship

Query a specific relationship type for a file with pagination support. Choose from 40 relationship types including behaviors, network connections, dropped files, embedded content, execution chains, and threat actors. Useful for detailed investigation of specific relationship types.

輸入參數hash必填limitcursorrelationship必填

get_ip_report

Get a comprehensive IP address analysis report including geolocation, reputation data, and key relationships (communicating files, historical certificates/WHOIS, resolutions). Returns both the basic analysis and automatically fetched relationship data.

輸入參數ip必填

get_ip_relationship

Query a specific relationship type for an IP address with pagination support. Choose from 15 relationship types including communicating files, historical SSL certificates, WHOIS records, resolutions, and threat actors. Useful for detailed investigation of specific relationship types.

輸入參數ip必填limitcursorrelationship必填

get_domain_report

Get a comprehensive domain analysis report including DNS records, WHOIS data, and key relationships (SSL certificates, subdomains, historical data). Optionally specify which relationships to include in the report. Returns both the basic analysis and relationship data.

輸入參數domain必填relationships

get_domain_relationship

Query a specific relationship type for a domain with pagination support. Choose from 24 relationship types including subdomains, resolutions, SSL certificates, WHOIS history, and threat actors. Useful for detailed investigation of specific relationship types.

輸入參數limitcursordomain必填relationship必填

search_vt

Search the VirusTotal corpus for files, URLs, domains, IPs, or comments matching a query. Accepts plain IOCs (hash, URL, domain, IP), free text against comments, or VTI-style search modifiers like "type:peexe size:90kb+ tag:signed positives:5+". Paginated via cursor.

輸入參數limitquery必填cursor

get_file_behaviour_summary

Get a consolidated sandbox behaviour summary for a file (MD5/SHA-1/SHA-256), merged across every sandbox that analyzed it. Returns processes, files, registry, network activity, MITRE ATT&CK techniques, IDS alerts, and signature matches in a single view — far more useful than iterating individual behaviour reports.

輸入參數hash必填

get_collection

Retrieve a VirusTotal collection by ID. Collections represent threat actors, malware families, campaigns, intel reports, and curated IOC sets — often referenced from the related_threat_actors and collections relationships on other tools. Optionally include relationships (files, urls, domains, ip_addresses, references, threat_actors, related_collections, related_references, comments, owner, autogenerated_graphs) to fetch member IOCs in the same call.

輸入參數id必填relationships

版本歷史

3
  1. v1.0.38最新Nov 5, 2026
  2. v1.0.37Nov 3, 2026
  3. v1.0.35Oct 14, 2026

評分

已滿足適用檢查項的 90%

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

  • 近 30 天內可連通25 分
  • 已宣告認證方式10 分

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

  • 已列出工具必需15 分
  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分