Event Mill
Enables direct analysis of log files stored in Google Cloud Storage buckets, including listing buckets and log objects, reading log segments and metadata, searching logs, and running GROK, regex, and AI-assisted analysis against GCS-hosted logs without central ingestion.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
Event Mill
Grinding Events into Intelligence
Event Mill is an open-source event record analysis platform supporting Security Operations and Detection Engineering teams. Analyze logs directly from Google Cloud Storage without ingesting them into a central SIEM.
Features
š AI-Powered Analysis - Gemini 3 Flash integration for intelligent log analysis
šÆ GROK Pattern Extraction - 25+ built-in patterns + custom pattern support
š 20 ECS Event Categories - Aligned with Elastic Common Schema
š OpenTelemetry Mappings - Semantic conventions for observability
š”ļø Threat Intelligence - AI-powered investigation with MITRE ATT&CK context
šÆ Threat Modeling - Analyze threat model PDFs and tabletop exercises for attack paths
āļø Modular Architecture - Extensible tool system for easy customization
š§ Detection Engineering - Generate GROK parsing templates for log pipelines
Related MCP server: Google Cloud Logging MCP Server
Prerequisites
Python 3.10+
Google Cloud Service Account with Storage Object Viewer permissions
Gemini API Key (optional, for AI features):
export GEMINI_API_KEY=your-key
Installation
pip install -r requirements.txtQuick Start
# Set environment variables
export GOOGLE_APPLICATION_CREDENTIALS=/path/to/service-account.json
export GEMINI_API_KEY=your-gemini-api-key # Optional
export GCS_LOG_BUCKET=your-log-bucket # Optional default bucket
# Run the CLI
python conversational_client.pyCommands Reference
š Navigation
Command | Description |
| List available event stores |
| Browse logs in bucket or folder |
| Read log content (first 100 lines) |
| Get file metadata |
š Analysis
Command | Description |
| Search for text in log file |
| Extract using GROK patterns (IP, HTTPSTATUS, etc.) |
| Expert mode with custom regex |
| AI-powered pattern discovery |
š Investigation (AI + Threat Intel)
Command | Description |
| Deep-dive AI analysis with MITRE ATT&CK context |
āļø Detection Engineering
Command | Description |
| Generate GROK parsing templates |
| Show GROK patterns & OTel mappings |
| List all analyze GROK patterns (built-in + custom) |
šÆ Threat Modeling & Attack Paths
Command | Description |
| Load threat intel PDF as context |
| Manage loaded threat intel context |
| Analyze threat model PDF |
| Analyze threat model text |
| Analyze tabletop exercise minutes |
| Manage threat scenarios |
| Create new threat scenario |
š¤ Natural Language
Just type naturally:
"Show me the top talkers from the web server logs"
"Investigate suspicious activity from IP 192.168.1.100"
"Find all authentication failures in the auth logs"
Examples
# List all buckets
ā mill> buckets
# Browse logs
ā mill> ls my-log-bucket/nginx
# Analyze top IPs using GROK pattern
ā mill> analyze IP access.log my-log-bucket
# Analyze HTTP status codes (full file)
ā mill> analyze HTTPSTATUS access.log my-log-bucket --full
# Expert regex mode
ā mill> analyze_rex "user=(\w+)" auth.log my-log-bucket
# AI-powered investigation
ā mill> investigate 192.168.1.100 access.log my-log-bucket
# Generate parsing templates
ā mill> templates access.log my-log-bucket --grok
# Natural language query
ā mill> show me top talkers from access.log
# Load threat intel context (PDF)
ā mill> load_pdf threatintel/m-trends-2025.pdf --gcs
# Analyze a threat model PDF
ā mill> threat_model threatmodels/webapp-tm.pdf --gcs
# Check defense gaps in a scenario
ā mill> scenarios gaps TS-0001
# Export scenario to markdown
ā mill> scenarios export TS-0001 output.mdThreat Modeling
Event Mill can analyze threat model documents and tabletop exercise minutes to extract attack paths and identify defense gaps.
Workflow
# 1. Load threat intelligence context (optional but recommended)
ā mill> load_pdf threatintel/m-trends-2025.pdf --gcs
ā
Threat Intel PDF Loaded
Document ID: TI-0001
Characters: 245,000
# 2. Analyze a threat model PDF
ā mill> threat_model threatmodels/webapp-threat-model.pdf --gcs
šÆ THREAT MODEL ANALYSIS (PDF)
š Threat Intel Context: 1 document(s) applied
...analysis output...
# 3. Create a scenario to track findings
ā mill> create_scenario "Ransomware via Phishing" "APT group targets employees with spear phishing"
ā
Threat Scenario Created
Scenario ID: TS-0001
# 4. View defense gaps
ā mill> scenarios gaps TS-0001
ā ļø UNPROTECTED ATTACK STEPS
- Step 3: Lateral Movement
š EASY-TO-BYPASS CONTROLS
- Email Gateway: low difficulty
# 5. Export to markdown report
ā mill> scenarios export TS-0001 threat-report.md
ā
Exported threat scenario to: threat-report.mdCapabilities
PDF Analysis: Extract text from threat model PDFs (local or GCS)
Threat Intel Context: Load background context from threat intel reports
Security Controls: Track controls by defense layer (perimeter, network, endpoint, etc.)
Attack Sequence: Map attack events with MITRE ATT&CK techniques
Gap Analysis: Identify unprotected steps, weak controls, and weakest points
Markdown Export: Generate reports with control coverage matrix
Source Types
Type | Description |
| Formal threat modeling documents (STRIDE, PASTA, etc.) |
| Penetration test reports, security audits |
| Red team engagement findings |
GROK Patterns
Built-in Patterns
Pattern | Description |
| IPv4 addresses |
| IPv6 addresses |
| MAC addresses |
| Email addresses |
| UUIDs |
| HTTP status codes |
| HTTP methods |
| Log levels (INFO, ERROR, etc.) |
| User identifiers |
| Port numbers |
| URL paths (without query string) |
| Full URI path (with query string) |
| URI path (alias for PATH) |
| Full URL with scheme (http/https) |
| ISO timestamps |
| Dates (YYYY-MM-DD) |
| Times (HH:MM:SS) |
| Integers |
| Numbers (with decimals) |
| Single words |
| Hostnames |
| Windows Security IDs |
Custom Patterns
Add organization-specific patterns in custom_patterns.py:
CUSTOM_GROK_PATTERNS = {
"MYAPP_TXID": r"TXN-(\d{8})",
"INTERNAL_UID": r"uid=(\w+)",
}See docs/CUSTOM_PATTERNS.md for detailed documentation.
Usage with Claude Desktop / Windsurf
Add this to your MCP configuration file:
{
"mcpServers": {
"event-mill": {
"command": "python",
"args": ["C:/path/to/gcs_soc_mcp/server.py"],
"env": {
"GOOGLE_APPLICATION_CREDENTIALS": "C:/path/to/service-account.json",
"GEMINI_API_KEY": "your-api-key",
"GCS_LOG_BUCKET": "your-default-bucket"
}
}
}
}MCP Tools Available
Navigation Tools
Tool | Description |
| List available GCS buckets |
| List files in a bucket or folder |
| Read chunks of a log file |
| Check file size and dates |
Search Tools
Tool | Description |
| Search for text in log files |
Analysis Tools
Tool | Description |
| Extract patterns using GROK names |
| Extract patterns using custom regex |
| Auto-detect log patterns with AI |
Investigation Tools
Tool | Description |
| AI-powered threat investigation |
| Common SOC analyst workflows |
Template Tools
Tool | Description |
| Generate GROK parsing templates |
| Show GROK patterns and OTel mappings |
Threat Modeling Tools
Tool | Description |
| Load threat intel PDF as context |
| Load threat intel text as context |
| List loaded threat intel documents |
| Clear threat intel context |
| Analyze threat model PDF |
| Analyze threat model text |
| Analyze tabletop exercise |
| Create threat scenario |
| Add security control to scenario |
| Add attack event to scenario |
| List all threat scenarios |
| Analyze defense gaps |
| Export scenario to markdown |
AI-Powered Features
Gemini 3 Flash Integration: Advanced threat intelligence analysis
Pattern Recognition: Automatic log type identification
Security Recommendations: Actionable next steps for analysts
MITRE ATT&CK Context: Threat intelligence with attack technique mapping
Pattern Template Generation
The generate_pattern_templates tool analyzes log files and generates structured parsing templates with:
Signature Mapping: Abstracted patterns showing variable data positions
GROK Patterns: Standard patterns for IPs, timestamps, HTTP methods, UUIDs, etc.
OpenTelemetry Mappings: Field names follow semantic conventions
Event Classification: 20 ECS categories (authentication, network, file, process, etc.)
Detection Logic: Boolean expressions to identify each pattern type
AI Review: Gemini reviews templates for accuracy and suggests improvements
Output formats:
Default (JSON): Human-readable with signature/example mapping for analysis
GROK (
--grok): Machine-readable config for Logstash/Filebeat pipelines
Architecture
Event Mill uses a modular architecture for easy maintenance and extension:
gcs_soc_mcp/
āāā server.py # MCP server entry point (78 lines)
āāā conversational_client_v2.py # CLI with Event Mill branding
āāā pattern_templates.py # GROK patterns, OTel mappings, ECS categories
āāā system_context.py # AI prompts and system context
āāā custom_patterns.py # User-defined GROK patterns
āāā tools/ # Modular MCP tool implementations
ā āāā __init__.py # Tool registration
ā āāā navigation.py # Bucket/file navigation tools
ā āāā search.py # Log search tools
ā āāā analysis.py # Pattern analysis tools
ā āāā investigation.py # AI investigation tools
ā āāā templates.py # Template generation tools
ā āāā threat_modeling.py # Threat modeling & attack path tools
āāā docs/ # Documentation
āāā CUSTOM_PATTERNS.md # Custom pattern guide
āāā DEPLOYMENT.md # Remote deployment guide
āāā EXTENDING_TOOLS.md # Tool development tutorialDeployment Options
1. Local / Cloud Shell (Stdio Mode)
Default mode - runs as a subprocess communicating via standard input/output.
python server.py2. Docker with ttyd Web Terminal
Run Event Mill as a web-accessible terminal using ttyd.
# Set environment variables
export GOOGLE_APPLICATION_CREDENTIALS=/path/to/service-account.json
export GEMINI_API_KEY=your-gemini-api-key
export GCS_LOG_BUCKET=your-log-bucket # Optional
export TTYD_USERNAME=admin # Optional, for basic auth
export TTYD_PASSWORD=changeme # Optional, for basic auth
# Build and run
docker-compose up --buildAccess the terminal at http://localhost:7681
Important: UID Matching
The Docker container runs as a non-privileged user. The UID specified in docker-compose.yml must match the OS UID of the user that owns your service account JSON key file:
# Check the UID of your key file owner
ls -n /path/to/service-account.json
# Example output: -rw------- 1 1002 1002 2358 Dec 29 17:58 service-account.json
# Update docker-compose.yml to match (default is 1000:1000)
user: "1002:1002"If the UIDs don't match, the container won't be able to read the mounted credentials file.
3. Google Cloud Run (SSE Mode)
Deploy as a standalone HTTP service:
gcloud run deploy event-mill \
--source . \
--region us-central1 \
--allow-unauthenticated \
--set-env-vars MCP_TRANSPORT=sse,GEMINI_API_KEY=your-keySee docs/DEPLOYMENT.md for detailed deployment instructions.
Documentation
Custom GROK Patterns - Add organization-specific patterns
Deployment Guide - Remote server and Cloud Run deployment
Extending MCP Tools - Tutorial for adding new tools
License
Licensed under the Apache License, Version 2.0. See LICENSE for details.
You are free to use, modify, and distribute this software. Attribution to the original Event Mill project is appreciated.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelogā¦
This server cannot be deployed
Maintenance
Related MCP Connectors
Search and SQL on object storage: full-text, vector and hybrid search plus SQL over your data.
Query your org's data in natural language ā read-only MCP access to SQL, NoSQL, files & warehouses.
Read-only Google Ads, GA4 and Search Console data for Claude, with no Google Cloud setup.
Query BigQuery, Snowflake, Redshift & Azure Synapse with natural language
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to interact with Google Cloud Platform services for log analysis and root cause investigation. Provides tools to query Cloud Logging, detect error patterns, and perform real-time log streaming across multiple GCP projects.MIT
- AlicenseNot gradedqualityFmaintenanceEnables AI assistants to query, search, and analyze logs across Google Cloud Platform projects. It supports advanced filtering by severity or resource type and provides detailed log entry retrieval and project listing capabilities.11MIT
- AlicenseBqualityDmaintenanceEnables AI-driven SOC investigations by providing automated Splunk querying, threat intelligence enrichment, and response actions through natural language. Includes tools for IP pivoting, lateral movement detection, and label harvesting.311Apache 2.0
- AlicenseNot gradedqualityDmaintenanceEnables security analysts and engineers to triage incidents, audit vulnerabilities, query multi-cloud telemetry, inspect network infrastructure, and automate ITSM remediations through natural language.MIT