IBM QRadar MCP Server
A Model Context Protocol (MCP) server that provides comprehensive access to IBM QRadar security intelligence platform. Query logs, events, offenses, agents, assets, and more directly from your AI assistant.
README
IBM QRadar MCP Server
A Model Context Protocol (MCP) server that provides comprehensive access to IBM QRadar security intelligence platform. Query logs, events, offenses, agents (log sources), assets, and more directly from your AI assistant.
Features
Core Capabilities (16 tools)
š Event & Log Queries
- Custom AQL Queries: Execute Ariel Query Language (AQL) queries against events and flows
- Recent Events: Quickly retrieve the latest security events
- Network Flows: Query network traffic data
šØ Offense Management
- List Offenses: Get all security offenses with filtering options
- Offense Details: Retrieve detailed information about specific offenses
- Filter by Status: Query open, closed, or offenses by severity
š„ļø Log Sources (Agents)
- List Log Sources: View all agents/collectors sending data to QRadar
- Log Source Details: Get configuration and status of specific log sources
- Log Source Types: Browse available log source types
š Asset Management
- List Assets: Query discovered network assets
- Search by IP: Find assets by IP address
- Asset Details: Get detailed asset information
š Analytics & Rules
- List Rules: Browse detection rules
- Rule Details: View rule configuration and logic
- Filter Rules: Find enabled/disabled rules
šļø Reference Data
- Reference Sets: Access threat intelligence lists
- Reference Data: Query specific reference set contents
āļø System Information
- System Info: QRadar version and configuration
- Server Status: Check QRadar server health
Advanced Features (25 additional tools) š
- š Offense Management: Add notes, update status, assign offenses, close with reasons
- š¾ Saved Searches: Execute and manage pre-configured AQL queries
- šØ Custom Properties: Work with user-defined event/flow enrichments
- š¢ Domain Management: Multi-tenant domain configuration and queries
- š Network Hierarchy: Access network topology and segment definitions
- š Discovery Tools: Introspect available fields, categories, and databases
- š§© Building Blocks: Manage reusable rule components
- š„ User Management: View users for offense assignment and collaboration
- š Reports: Access installed applications and report templates
Total: 41 comprehensive tools for complete security operations
See ADVANCED_FEATURES.md for detailed documentation on all advanced capabilities
Installation
š Quick Start Guides
- ā” 5-Minute Setup: QUICK_DEPLOY.md - Get running FAST
- š Complete Guide: GETTING_STARTED.md - Detailed walkthrough
- ā Deployment Checklist: DEPLOYMENT_CHECKLIST.md - Step-by-step verification
Prerequisites
- Python 3.10 or higher
- IBM QRadar instance with API access
- API authentication token from QRadar
- AI Client: Claude Desktop, or any local LLM (Ollama, LM Studio, etc.)
š” New: You can now use local open-source LLMs instead of Claude! See LOCAL_LLM_GUIDE.md for setup.
Setup
- Clone the repository:
git clone <repository-url>
cd IBMQradarMCP
- Install dependencies:
pip install -r requirements.txt
- Configure environment variables:
cp .env.example .env
Edit .env file with your QRadar credentials:
QRADAR_HOST=your-qradar-host.com
QRADAR_API_TOKEN=your-api-token-here
QRADAR_VERIFY_SSL=true
Getting QRadar API Token
- Log into your QRadar console
- Navigate to Admin > Authorized Services
- Click Create Authorized Service
- Provide a name and select appropriate permissions
- Copy the generated token to your
.envfile
Usage
Running the MCP Server
python -m src.server
The server will start and communicate via stdio (standard input/output) as per the MCP protocol.
Configuration with AI Clients
Option 1: Claude Desktop
Add this configuration to your Claude Desktop config file:
MacOS: ~/Library/Application Support/Claude/claude_desktop_config.json
Windows: %APPDATA%/Claude/claude_desktop_config.json
{
"mcpServers": {
"qradar": {
"command": "python",
"args": ["-m", "src.server"],
"cwd": "/path/to/IBMQradarMCP",
"env": {
"QRADAR_HOST": "your-qradar-host.com",
"QRADAR_API_TOKEN": "your-api-token",
"QRADAR_VERIFY_SSL": "true"
}
}
}
}
Option 2: Local LLMs (Ollama, LM Studio, etc.) š
Quick Start with Ollama:
# 1. Install Ollama
brew install ollama # or visit ollama.com
# 2. Download a model
ollama pull llama3.1:8b
# 3. Run setup script
./setup_local_llm.sh
# 4. Start the local client (choose one):
# Option A: Web UI (recommended - beautiful interface) š
./start_webui.sh
# Then open http://localhost:5000
# Option B: Terminal client (simple, lightweight)
python3 local_llm_client.py
Local LLM Interfaces Available:
- š Web UI - Beautiful, modern web interface (NEW!)
- š» Terminal Client - Command-line interface
- š§ Continue.dev - VS Code integration
- š„ļø LM Studio - Desktop app with GUI
- š Open WebUI - Advanced web interface
- š Jan.ai - Privacy-focused desktop app
Supported Local LLMs:
- ā Ollama (recommended)
- ā LM Studio
- ā Continue.dev (VS Code)
- ā Open WebUI
- ā Jan.ai
š Guides:
- WEB_UI_GUIDE.md - Beautiful web interface setup š
- LOCAL_LLM_GUIDE.md - Complete local LLM guide
Available Tools
Event & Log Query Tools
qradar_search_events
Search events using AQL (Ariel Query Language).
Parameters:
query(required): AQL query stringtimeout(optional): Query timeout in seconds (default: 60)max_wait(optional): Maximum wait time for results (default: 300)
Example:
Search for failed login attempts in the last 24 hours:
SELECT sourceip, username, eventcount FROM events WHERE category=1003 LAST 24 HOURS
qradar_get_recent_events
Get the most recent security events.
Parameters:
limit(optional): Number of events to return (default: 50)fields(optional): Array of field names to return
qradar_search_flows
Search network flows using AQL.
Parameters:
query(required): AQL query string for flowstimeout(optional): Query timeout in secondsmax_wait(optional): Maximum wait time for results
Offense Tools
qradar_get_offenses
Get offenses (security incidents) from QRadar.
Parameters:
filter(optional): Filter string (e.g., "status=OPEN")fields(optional): Comma-separated list of fieldsrange(optional): Result range (e.g., "0-49")
qradar_get_offense_by_id
Get detailed information about a specific offense.
Parameters:
offense_id(required): The offense ID
Log Source (Agent) Tools
qradar_get_log_sources
List all log sources (agents/collectors).
Parameters:
filter(optional): Filter string (e.g., "enabled=true")fields(optional): Comma-separated list of fields
qradar_get_log_source_by_id
Get details of a specific log source.
Parameters:
log_source_id(required): The log source ID
qradar_get_log_source_types
Get available log source types.
Asset Tools
qradar_get_assets
List network assets discovered by QRadar.
Parameters:
filter(optional): Filter stringfields(optional): Comma-separated list of fields
qradar_search_assets_by_ip
Search for assets by IP address.
Parameters:
ip_address(required): IP address to search
Reference Data Tools
qradar_get_reference_sets
List all reference data sets.
qradar_get_reference_set_data
Get data from a specific reference set.
Parameters:
ref_set_name(required): Name of the reference set
System Information Tools
qradar_get_system_info
Get QRadar system information.
qradar_get_servers
Get QRadar server/host information.
Rules Tools
qradar_get_rules
List analytics rules.
Parameters:
filter(optional): Filter stringfields(optional): Comma-separated list of fields
qradar_get_rule_by_id
Get details of a specific rule.
Parameters:
rule_id(required): The rule ID
Example Queries
Here are some example queries you can ask your AI assistant once the MCP server is configured:
Security Monitoring
- "Show me all open offenses with high severity"
- "What are the most recent security events in the last hour?"
- "Search for failed SSH login attempts in the last 24 hours"
Network Analysis
- "Show me all network flows from IP 192.168.1.100"
- "What are the top source IPs in network traffic today?"
Asset Management
- "List all assets in my network"
- "Find information about the asset with IP 10.0.0.50"
- "What log sources are currently connected?"
Threat Investigation
- "Show me details of offense ID 1234"
- "What reference sets contain the IP 8.8.8.8?"
- "List all enabled detection rules"
AQL Query Examples
Event Queries
Failed login attempts:
SELECT sourceip, username, eventcount
FROM events
WHERE category=1003
LAST 24 HOURS
High severity events:
SELECT sourceip, destinationip, qid
FROM events
WHERE severity >= 7
LAST 1 HOURS
Events from specific IP:
SELECT *
FROM events
WHERE sourceip='192.168.1.100'
LAST 7 DAYS
Flow Queries
Top talkers by bytes:
SELECT sourceip, destinationip, SUM(sourcebytes) as total_bytes
FROM flows
GROUP BY sourceip, destinationip
ORDER BY total_bytes DESC
LAST 1 HOURS
Connections to specific port:
SELECT sourceip, destinationip, destinationport
FROM flows
WHERE destinationport=443
LAST 24 HOURS
Security Considerations
- API Token Security: Never commit your API token to version control
- SSL Verification: Keep
QRADAR_VERIFY_SSL=truein production - Least Privilege: Use QRadar authorized services with minimal required permissions
- Network Security: Ensure secure network connection to QRadar
- Token Rotation: Regularly rotate API tokens
Troubleshooting
Connection Issues
Error: QRadar API request failed
- Verify
QRADAR_HOSTis correct (without https://) - Check firewall rules allow connection to QRadar
- Ensure API port (typically 443) is accessible
Authentication Errors
Error: 401 Unauthorized
- Verify
QRADAR_API_TOKENis correct - Check token hasn't expired in QRadar
- Ensure authorized service has required permissions
SSL Certificate Errors
Error: SSL verification failed
- For development, set
QRADAR_VERIFY_SSL=false - For production, add QRadar certificate to trusted certificates
Query Timeout
Error: Search timed out
- Increase
max_waitparameter - Narrow your query time range
- Use more specific filters in AQL
Development
Project Structure
IBMQradarMCP/
āāā src/
ā āāā __init__.py
ā āāā qradar_client.py # QRadar API client
ā āāā server.py # MCP server implementation
āāā pyproject.toml # Project metadata
āāā requirements.txt # Dependencies
āāā .env.example # Environment template
āāā README.md # Documentation
Testing
Run the server in debug mode:
python -m src.server
Test with sample MCP client or integrate with Claude Desktop.
API Reference
This MCP server uses IBM QRadar REST API v15.0. For more information:
Author
Ram Krishna Katakwar
License
See LICENSE file for details.
Contributing
Contributions are welcome! Please feel free to submit pull requests or open issues.
Support
For issues and questions:
- Check the troubleshooting section
- Review QRadar API documentation
- Open an issue on GitHub
Changelog
Version 0.2.0
- š 25 new advanced tools added (total: 41 tools)
- ⨠Enhanced offense management: notes, status updates, assignment, closing
- š¾ Saved search execution and management
- šØ Custom property discovery and querying
- š¢ Domain management for multi-tenancy
- š Network hierarchy access
- š Discovery tools: fields, categories, databases
- š§© Building block management
- š„ User management for assignment
- š Reports and applications listing
- š Comprehensive advanced features documentation
Version 0.1.0
- Initial release
- Event and flow queries with AQL support
- Offense management
- Log source (agent) information
- Asset queries
- Reference data access
- System information
- Rules browsing
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.