Enrichment MCP Server

Enrichment MCP Server

A Model Context Protocol server that enables users to perform third-party enrichment lookups for security observables (IP addresses, domains, URLs, emails) through services like VirusTotal, Shodan, and others.

Category
访问服务器

README

Enrichment MCP Server

A Model Context Protocol (MCP) server for performing enrichment given a provided observable. The combination of configured services and the provided observable(s) will determine which enrichment services to utilize.

This tool provides a simple implementation to perform third-party enrichment using common services (e.g. VirusTotal, Hybrid Analysis, etc.).

This project is has not been used in any production setting.

Features

This implementation of the enrichment-mcp MCP server exposes the following tools.

  • observable-lookup - A generic endpoint which examines and routes the given observable to the correct tool.
  • lookup-ipaddress - Performs enrichment on a given IPv4 address.
  • lookup-domain - Performs enrichment on a given domain name.
  • lookup-url - Performs enrichment on a given URL (and in some cases domain name).
  • lookup-email - Performs enrichment of a given email address.

If you encounter an issue with the determined observable type, then please create an issue or I can update the current implemented regex patterns.

Supported Services

The following services and observable types are currently supported:

If you have any suggestions or believe another service should be implemented, please create an issue or pull request!

Name API Key Required Supports IP Supports Domain Supports URL Supports Email
VirusTotal Yes Yes Yes Yes No
HybridAnalysis Yes Yes Yes Yes No
AlienVault Yes Yes Yes Yes No
Shodan Yes Yes Yes Yes No
Urlscan.io Yes Yes Yes Yes No
AbuseIPDB Yes Yes No No No
HaveIBeenPwned Yes No No No Yes

Requirements

This MCP service implements a custom config file that is used to determine which third-party enrichment services should be used for observable lookups.

Since this is purely for development / testing at this current time, the easiest way to run this on a local mac/system is:

uv run --env-file .env server.py

This requires that you use the provided template .env.example and create a new .env file with your secrets.

config.yaml

This project provides a custom configuration file and I believe it's pretty easy to understand.

First, copy the provided config.yaml.example config and remove the .example extension before using this service.

Within this configuration file there are two main sections of data; server and enrichments.

By default, all services supported are mapped to the current implemented enrichment action types. Currently, the only true enrichment action type is lookups but other may be implemented in the future.

Under the lookups we have the different supported enrichment types.

That being said, each individual service can have a key named apikey and the API key value from that service but please consider not doing so.

You can set this keys value directly in the config.yaml.example but the preferred way is to use a .env.

NOTE: It is highly recommended to set secrets as environmental variables when implementing this service. Stop storing secrets silly goose.

In order for this service to discover these variables, they must be in a specific format. Below is the list of currently supported variables:

  • ENRICHMENT_MCP_VIRUSTOTAL_KEY
  • ENRICHMENT_MCP_HYBRIDANALYSIS_KEY
  • ENRICHMENT_MCP_ALIENVAULT_KEY
  • ENRICHMENT_MCP_SHODAN_KEY
  • ENRICHMENT_MCP_URLSCAN_KEY
  • ENRICHMENT_MCP_ABUSEIPDB_KEY
  • ENRICHMENT_MCP_HIBP_KEY

Server Configuration

There are minimal settings here as this is mostly for sandboxing and testing, but these settings typically do not need to be changed or altered for this service to work.

server:
  host: 0.0.0.0 # the host address
  port: 8000 # the port
  debug: false # whether to enable debug logging
  log_level: INFO # the default logging level

Enrichments Configuration

Each enrichment in our config file resides under the enrichments key. Additionally, I have broken out the different types of enrichment that can be performed. This means, in the current implementation, we only have a single action type called lookups but in the future this can be expanded for things like scans or queries etc.

Underneath these high-level actions, we list out the observable type followed by a list of services that support that type. The currently supported observable types are:

  • ipaddress - ipv4 addresses
  • domain - A domain or netloc
  • url - A fully qualified URL with schema, etc.
  • email - A standard email address

We also support these types but they are currently not implemented:

  • md5 - A file MD5 hash
  • sha1 - A file SHA1 hash
  • sha256 - A file SHA256 hash

Each service must have a name and a template. The apikey field can be provided but it is recommended to use environmental variables.

Prompt Templates

Each service and observable type can have it's own template. These reside in the templates directory and all templates are expected to exist here.

Each service defined has a prompt template using jinja2 templates. You can modify these are needed, but the format of the filename must remain the same.

These files have the following filename pattern.

{service.name}.{enrichment.type}.jinja2

Additionally, ensure that the response object has the correct fields in the template itself or you will receive an error.

Below is an example output for a prompt of Enrich this IP 91.195.240.94 with some errors mixed in:

{
    "virustotal": "error occurred looking up ip 91.195.240.94 in virustotal",
    "alienvault": "Service: alienvault\nIPAddress: \nReputation Score: 0\nTotal Votes: ",
    "shodan": "Service: shodan\nIPAddress: 91.195.240.94\nLast Analysis Results: 2025-04-25T21:02:52.644602\n\nTags\n\n\nAdditional information includes:\n\n* Latitude: 48.13743\n* Longitude: 11.57549\n* ASN: AS47846\n* Domains: ["servervps.net"]",
    "hybridanalysis": "error occurred looking up ip 91.195.240.94 in hybridanalysis",
    "urlscan": "Service: urlscan\nResult: https://urlscan.io/api/v1/result/01966efe-c8fa-74a4-bfc0-1ed479838e85/\n\nStats\n\n* uniqIPs - 6\n\n* uniqCountries - 2\n\n* dataLength - 432561\n\n* encodedDataLength - 218606\n\n* requests - 14\n\n\nPage\n* country - DE\n* server - Parking/1.0\n* ip - 91.195.240.94\n* mimeType - text/html\n* title - wearab.org\xa0-\xa0Informationen zum Thema wearab.\n* url - https://login.wearab.org/\n* tlsValidDays - 364\n* tlsAgeDays - 0\n* tlsValidFrom - 2025-04-25T00:00:00.000Z\n* domain - login.wearab.org\n* apexDomain - wearab.org\n* asnname - SEDO-AS SEDO GmbH, DE\n* asn - AS47846\n* tlsIssuer - Encryption Everywhere DV TLS CA - G2\n* status - 200\n",
    "abuseipdb": "Service: abuseripdb\nIPAddress: 91.195.240.94\nLast Analysis Result: 2025-03-30T14:04:45+00:00\nScore: 7\nUsage: Data Center/Web Hosting/Transit\nIs Tor: False\nIs Whitelisted: False\nISP: Sedo Domain Parking"
}

Usage

For using a pre-built server, instructions from here: https://modelcontextprotocol.io/quickstart/user

  • Download Claude for Desktop
  • Install uv
curl -LsSf https://astral.sh/uv/install.sh | sh
  • Download this repo and add to Claude for Desktop config
    • Claude for Desktop > Settings > Developer > Edit Config

This will create a configuration file at:

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

Open up the configuration file in any text editor. Replace the file contents with this:

{
	"mcpServers": {
		"enrichment-mcp": {
			"command": "/ABSOLUTE/PATH/TO/PARENT/FOLDER/uv",
			"args": [
				"--directory",
				"/ABSOLUTE/PATH/TO/CLONED/REPOSITORY/enrichment-mcp",
				"run",
				"server.py"
			]
		}
    }
}
  1. Relaunch Claude for Desktop

You should now see two icons in the chat bar, a hammer which shows the tools available and a connection icon which shows the prompt defined and the input required.

Design

While building this server, I was learning astral uv as well as MCP. I definitely over engineered this but it was fun. I also had future uses for some of this code so I tried to design it with that in mind as well (more to come on that).

Additionally, I specifically moved to Jinja2 templates as this enables better management of the returned prompts/results and, again, furture use cases as well.

Please provide any feedback, improvements or feature requests; glad to hear them all.

Contributing

Contributions are welcome! Please feel free to submit pull requests.

Disclaimer

This tool is for educational and authorized testing purposes only.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选