
SecurityOnion MCP Server

2025.05.05
0
Python安全监控日志管理其它
SecurityOnion MCP Server 是一个专为 Security Onion (v2.3.1+) 设计的独立服务器,用于管理 MCP 通信工作流。它提供了一个灵活的基础架构,可以通过添加子服务器到 tools/ 目录来扩展功能。该项目适用于需要定制化 MCP 通信解决方案的环境,尤其是在安全监控和日志管理领域。
View on GitHub
Overview
基本能力
产品定位
SecurityOnion MCP Server 是一个用于 Security Onion 平台的 MCP 通信管理服务器,旨在提供灵活的通信工作流管理能力。
核心功能
- 支持 MCP 通信工作流管理。
- 可通过添加子服务器扩展功能。
- 提供工具调用接口,支持 ElasticSearch 和文件操作等功能。
适用场景
- 安全监控环境中的日志管理。
- 需要定制化 MCP 通信解决方案的场景。
- 企业级安全运维环境。
工具列表
tools/so_elasticsearch_mcp
earch_elasticsearch
: 用于 ElasticSearch 搜索。list_indices
: 列出 ElasticSearch 索引。tools/so_files_mcp
get_zeek_file
: 获取 Zeek 文件。get_suricata_pcap
: 获取 Suricata pcap 文件。get_strelka_file
: 获取 Strelka 文件。
常见问题解答
- 安装失败:确保 SecurityOnion 有互联网连接。
- 防火墙配置:需要允许端口 5001 的入站连接。
- Python 版本:必须安装 Python 3.10。
使用教程
使用依赖
- 安装开发工具和依赖库:
shell sudo dnf install -y oraclelinux-release-el9 dnf-utils sudo dnf config-manager --enable ol9_codeready_builder sudo dnf repolist enabled sudo dnf groupinstall "Development Tools" -y sudo dnf install gcc openssl-devel bzip2-devel libffi-devel wget make zlib-devel -y
- 安装 Python 3.10:
shell cd /usr/src sudo wget https://www.python.org/ftp/python/3.10.14/Python-3.10.14.tgz sudo tar xzf Python-3.10.14.tgz cd Python-3.10.14 sudo ./configure --enable-optimizations sudo make -j$(nproc) sudo make altinstall
安装教程
- 克隆仓库并运行安装脚本:
shell cd securityonion-mcp ./install.sh
- 按照提示输入 Security Onion 的主机、用户名和密码。
调试方式
- 运行服务器:
shell ./run.sh
- 配置防火墙以允许端口 5001 的通信:
shell sudo iptables -I INPUT -p tcp --dport 5001 -j ACCEPT
或使用 firewalld:shell sudo firewall-cmd --zone=SecurityOnion --add-port=5001/tcp --permanent sudo firewall-cmd --reload