Skip to main content

Google Threat Intelligence MCP Server

This is an MCP (Model Context Protocol) server for interacting with Google's Threat Intelligence suite. MCP Info

Features

Collections (Threats)

  • get_collection_report(id): Retrieves a specific collection report by its ID (e.g., report--<hash>, threat-actor--<hash>).
  • get_entities_related_to_a_collection(id, relationship_name, limit=10): Gets related entities (domains, files, IPs, URLs, other collections) for a given collection ID.
  • search_threats(query, limit=5, order_by="relevance-"): Performs a general search for threats (collections) using GTI query syntax.
  • search_campaigns(query, limit=10, order_by="relevance-"): Searches specifically for collections of type campaign.
  • search_threat_actors(query, limit=10, order_by="relevance-"): Searches specifically for collections of type threat-actor.
  • search_malware_families(query, limit=10, order_by="relevance-"): Searches specifically for collections of type malware-family.
  • search_software_toolkits(query, limit=10, order_by="relevance-"): Searches specifically for collections of type software-toolkit.
  • search_threat_reports(query, limit=10, order_by="relevance-"): Searches specifically for collections of type report.
  • search_vulnerabilities(query, limit=10, order_by="relevance-"): Searches specifically for collections of type vulnerability.
  • get_collection_timeline_events(id): Retrieves curated timeline events for a collection.

Files

  • get_file_report(hash): Retrieves a comprehensive analysis report for a file based on its MD5, SHA1, or SHA256 hash.
  • get_entities_related_to_a_file(hash, relationship_name, limit=10): Gets related entities (domains, IPs, URLs, behaviours, etc.) for a given file hash.
  • get_file_behavior_report(file_behaviour_id): Retrieves a specific sandbox behavior report for a file.
  • get_file_behavior_summary(hash): Retrieves a summary of all sandbox behavior reports for a file hash.
  • analyse_file(file_path): Uploads and analyzes a local file in VirusTotal. Disabled by default; set GTI_ALLOWED_UPLOAD_DIR to an absolute directory path to enable uploads of regular files within that directory. Uploaded files are shared with the VirusTotal community.
  • search_iocs(query, limit=10, order_by="last_submission_date-"): Searches for Indicators of Compromise (files, URLs, domains, IPs) using advanced GTI query syntax.

Network Locations (Domains & IPs)

  • get_domain_report(domain): Retrieves a comprehensive analysis report for a domain.
  • get_entities_related_to_a_domain(domain, relationship_name, limit=10): Gets related entities for a given domain.
  • get_ip_address_report(ip_address): Retrieves a comprehensive analysis report for an IPv4 or IPv6 address.
  • get_entities_related_to_an_ip_address(ip_address, relationship_name, limit=10): Gets related entities for a given IP address.

URLs

  • get_url_report(url): Retrieves a comprehensive analysis report for a URL.
  • get_entities_related_to_an_url(url, relationship_name, limit=10): Gets related entities for a given URL.

Hunting

  • get_hunting_ruleset: Get a Hunting Ruleset object from Google Threat Intelligence
  • get_entities_related_to_a_hunting_ruleset: Retrieve entities related to the the given Hunting Ruleset.

Threat Profiles

  • list_threat_profiles: List your Threat Profiles at Google Threat Intelligence.
  • get_threat_profile(profile_id): Get Threat Profile object.
  • get_threat_profile_recommendations(profile_id, limit=10): Returns the list of objects associated to the given Threat Profile.
  • get_threat_profile_associations_timeline(profile_id): Retrieves the associations timeline for the given Threat Profile.

Configuration

MCP Server Configuration

Add the following configuration to your MCP client's settings file:

NOTE: For OSX users, if you used this one-liner to install uv, use the full path to the uv binary for the "command" value below, as uv will not be placed in the system path for Claude to use! For example: /Users/yourusername/.local/bin/uv instead of just uv.

{
  "mcpServers": {
    "gti": {
      "command": "uv",
      "args": [
        "--env-file=/path/to/your/env",
        "--directory",
        "/path/to/the/repo/server/gti/gti_mcp",
        "run",
        "server.py"
      ],
      "env": {
        "VT_APIKEY": "${VT_APIKEY}"
      },
      "disabled": false,
      "autoApprove": []
    }
  }
}

Environment Variable Setup

Set up the environment variables in your system:

  • VT_APIKEY (required): Your VirusTotal API key.
  • GTI_ALLOWED_UPLOAD_DIR (optional): Absolute path to an existing local directory for file uploads. When set, registers the analyse_file tool and restricts uploads to regular files within this directory (must not be the filesystem root). If set to an invalid value (such as a relative path, non-existent path, non-directory, or filesystem root), the server raises a ValueError and refuses to start.

For macOS/Linux:

export VT_APIKEY="your-vt-api-key"
export GTI_ALLOWED_UPLOAD_DIR="/path/to/uploads"

For Windows PowerShell:

$Env:VT_APIKEY = "your-vt-api-key"
$Env:GTI_ALLOWED_UPLOAD_DIR = "C:\path\to\uploads"

License

Apache 2.0

Development

The project is structured as follows:

  • gti_mcp/server.py: Main MCP server implementation
  • gti_mcp/utils.py: Utils to consume VirusTotal API using vt-py library.
  • gti_mcp/tools/: Folder containing tools.

Metadata

Release files for gti-mcp 0.1.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for gti-mcp 0.1.4
File Size Uploaded Provenance Actions
gti_mcp-0.1.4.tar.gz 49.6 kB Without provenance Details for gti_mcp-0.1.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for gti-mcp 0.1.4
File Interpreter ABI Platform Actions
gti_mcp-0.1.4-py3-none-any.whl Python 3 none any Details for gti_mcp-0.1.4-py3-none-any.whl

Total release size: 107.8 kB

Release files / gti_mcp-0.1.4.tar.gz

Download URL gti_mcp-0.1.4.tar.gz
Size 49.6 kB
Tags Source
SHA-256 checksum
How to use checksums
655126bc7630d48592c085ed240019e818c1e300673f2e9aae491c4369f9b4c8
BLAKE2b-256 checksum
How to use checksums
1964271c4df1149083c3253f85ccc0c66c2df66a2e1d27c2affc8dff5b674075
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.18

Release files / gti_mcp-0.1.4-py3-none-any.whl

Download URL gti_mcp-0.1.4-py3-none-any.whl
Size 58.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
886c62cb72cd2d438ca590c80b3ad10dd67ff7959d9c816b2f88cb16ef9698b1
BLAKE2b-256 checksum
How to use checksums
56f7dc43638c7cad171492d800ce53a33b93e326b2321e974807009304de3738
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.18

Security for gti-mcp 0.1.4

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page