Wazuh MCP Server
Enables integration between Wazuh security platform and AI applications through the MCP framework, providing tools for security analysis, agent management, and system monitoring.
README
Wazuh MCP Server
Model Context Protocol (MCP) servers for Wazuh services, providing seamless integration between Wazuh security platform and AI applications through the MCP framework.
🚀 Quick Start
Get started in 5 minutes with our comprehensive documentation:
- 📚 Documentation Overview - Start here for complete guide
- ⚡ Quick Start Guide - 5-minute setup
- 🐳 Docker Deployment - Production deployment
- 📖 API Reference - Complete API documentation
- 🔧 Configuration Guide - Configuration reference
- 🛠️ Tools Reference - All available tools
- 📋 Installation Guide - Detailed installation
- 🔍 Troubleshooting - Common issues and solutions
📁 Project Structure
wazuh-mcp-server/
├── src/ # Source code package
│ └── wazuh_mcp_server/ # Main application package
│ ├── wazuh_indexer/ # Wazuh Indexer MCP Server
│ │ ├── config/ # Configuration modules
│ │ │ ├── base_config.py
│ │ │ └── indexer_config.py
│ │ ├── services/ # Service implementations
│ │ │ └── indexer_service.py
│ │ ├── utils/ # Utilities
│ │ │ └── logger.py
│ │ ├── tools/ # MCP tools
│ │ │ ├── cluster_tools.py
│ │ │ ├── index_tools.py
│ │ │ ├── monitoring_tools.py
│ │ │ ├── search_tools.py
│ │ │ ├── security_tools.py
│ │ │ └── tool_clients.py
│ │ └── server.py # Main server entry point
│ ├── wazuh_manager/ # Wazuh Manager MCP Server
│ │ ├── config/ # Configuration modules
│ │ │ ├── base_config.py
│ │ │ └── manager_config.py
│ │ ├── services/ # Service implementations
│ │ │ └── manager_service.py
│ │ ├── utils/ # Utilities
│ │ │ └── logger.py
│ │ ├── tools/ # MCP tools
│ │ │ ├── agents.py
│ │ │ ├── api_info.py
│ │ │ ├── cluster.py
│ │ │ ├── decoders.py
│ │ │ ├── experimental.py
│ │ │ ├── groups.py
│ │ │ ├── lists.py
│ │ │ ├── manager.py
│ │ │ ├── mitre.py
│ │ │ ├── overview.py
│ │ │ ├── rootcheck.py
│ │ │ ├── rules.py
│ │ │ ├── sca.py
│ │ │ ├── security.py
│ │ │ ├── syscollector.py
│ │ │ ├── syscheck.py
│ │ │ ├── tasks.py
│ │ │ └── wazuh_manager_base_api.py
│ │ └── server.py # Main server entry point
│ ├── server_manager.py # Server management CLI
│ └── __init__.py # Package initialization
├── deployment/ # Docker deployment
│ ├── .env.docker.example # Docker environment template
│ ├── .env.production.example # Production environment template
│ ├── docker/
│ │ ├── docker-compose.yml
│ │ ├── Dockerfile
│ │ └── nginx.conf
│ ├── requirements-mcp.txt # Python dependencies
│ └── README.md # Deployment documentation
├── docs/ # Documentation
├── tests/ # Test suite
├── .env.example # Environment configuration template
├── pyproject.toml # Modern Python package configuration
├── SECURITY.md # Security policy
├── CHANGELOG.md # Version history
└── README.md # Project documentation
Features
- Self-Contained: Each MCP server has its own complete module structure
- Modular Architecture: Clean separation of concerns within each server
- Docker Ready: Deployable via Docker Compose
- Warning Suppression: Deprecation and runtime warnings are filtered
- Local Imports: All imports are relative to prevent external dependencies
- Clean Logging: Production-ready log output with reduced verbosity
Logging
The MCP servers use structured logging with the following levels:
- ERROR: Authentication failures, connection errors, critical issues
- WARNING: JWT expiration, recoverable issues, deprecated usage
- INFO: Startup messages, connection success, tool registration summaries
- DEBUG: Data fetching operations, detailed API interactions (disabled by default)
Log Output Examples
✅ Successfully connected to Wazuh API
✅ Successfully imported and registered 106 Wazuh Manager tools from 18 modules
✅ Successfully imported and registered 36 Wazuh Indexer tools from 5 modules
Verbose debug logging (API requests, data fetching operations) has been moved to DEBUG level to reduce log noise while maintaining troubleshooting capabilities when needed.
Architecture Changes
Tool Migration
The tools have been restructured for better organization:
- Wazuh Indexer tools are located in
wazuh_indexer/tools/ - Wazuh Manager tools are located in
wazuh_manager/tools/
Import Cleanup
- Removed external imports:
from utils.logger import logger - Removed external imports:
from config.wazuh_config import WazuhConfig - Removed configuration instantiation:
config = WazuhConfig() - Updated to use centralized service instances set by servers
Service Integration
Each MCP server now:
- Creates its own service instance (WazuhIndexerMCPService/WazuhManagerMCPService)
- Patches tool clients to use the centralized service
- Imports and registers tools using relative imports
- Handles all configuration through environment variables
⚡ Quick Installation
# 1. Clone repository
git clone https://github.com/RayaSatriatama/wazuh-mcp-server.git
cd wazuh-mcp-server
# 2. Deploy with Docker (recommended)
docker compose --profile http up -d
# 3. Verify deployment
curl http://localhost:8001/health # Indexer
curl http://localhost:8002/health # Manager
For detailed installation instructions, see the Installation Guide.
🎛️ Server Management
Use the built-in server manager for easy development and testing:
# Start all MCP servers
uvx --from fastmcp python -m src.wazuh_mcp_server.server_manager start-all
# Check server status
uvx --from fastmcp python -m src.wazuh_mcp_server.server_manager status
# Stop all servers
uvx --from fastmcp python -m src.wazuh_mcp_server.server_manager stop-all
# Start individual servers
uvx --from fastmcp python -m src.wazuh_mcp_server.server_manager start wazuh_indexer
uvx --from fastmcp python -m src.wazuh_mcp_server.server_manager start wazuh_manager
🏗️ Architecture
The Wazuh MCP Server provides two main services:
- Wazuh Indexer MCP Server (Port 8001) - Search, alerts, analytics
- Wazuh Manager MCP Server (Port 8002) - Agents, rules, management
🚀 Transport Modes
- HTTP Mode - Production REST API (ports 8001/8002)
- SSE Mode - Real-time Server-Sent Events (ports 8003/8004)
- STDIO Mode - Direct MCP client integration
For detailed architecture and configuration, see:
🔧 Features
- Comprehensive Wazuh Integration - Full access to Wazuh Manager and Indexer APIs
- Multi-Transport Support - HTTP, SSE, and STDIO modes for different use cases
- Modular Architecture - Clean separation of concerns with service layers
- Production Ready - Docker deployment with health checks and monitoring
- MCP Compatible - Native integration with Model Context Protocol clients
- Rich Tool Set - 140+ tools for security analysis, agent management, and system monitoring
Available Tools
Wazuh Indexer Tools (36 tools):
- Alert search and analytics
- Vulnerability management
- Cluster health monitoring
- Index management
- Search aggregations
Wazuh Manager Tools (106 tools):
- Agent management and monitoring
- Rule and decoder management
- Group and configuration management
- Security compliance (SCA, CIS-CAT)
- System monitoring (Syscheck, Rootcheck)
For complete tool documentation, see Tools Reference.
🤝 Contributing
We welcome contributions! Please see our Development Guide for:
- Development environment setup
- Code style guidelines
- Testing procedures
- Pull request process
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
🆘 Support
- Documentation: docs/ folder contains comprehensive guides
- Issues: Report bugs and feature requests on GitHub Issues
- Troubleshooting: See Troubleshooting Guide
🎯 Project Status
✅ PRODUCTION READY - The Wazuh MCP Server is fully functional and ready for production use with comprehensive documentation, Docker deployment, and multi-transport support.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。