Open-source attack investigation and incident narrative engine
Project description
soc-chronicle
Open-source Attack Investigation & Incident Narrative Engine — transforms raw cybersecurity alerts into complete, evidence-driven attack narratives.
Vision
soc-chronicle sits between existing detection platforms (SIEM, EDR, XDR, Cloud Security, IDS/IPS) and incident response workflows. Unlike traditional SIEMs that collect and search logs, soc-chronicle focuses on:
- Investigation automation — correlate events, build attack graphs, reconstruct timelines
- Evidence correlation — every conclusion traces back to supporting evidence
- Root cause analysis — patient zero, initial compromise, blast radius
- Deterministic analysis — explainable outputs, no black-box scoring
Quick Start
# Install
pip install -e ".[dev]"
# Run an investigation
chronicle investigate examples/alert.json --logs examples/logs
# Export report
chronicle investigate examples/alert.json --logs examples/logs -o report.md
# Extract IOCs
chronicle enrich indicators.txt
# Build timeline from logs
chronicle timeline examples/logs/
Python API
from soc_chronicle import InvestigationEngine
engine = InvestigationEngine()
report = engine.investigate(
alert="examples/alert.json",
logs="./examples/logs",
)
print(report.summary)
print(report.narrative)
print(f"Risk: {report.risk.total_score}/100")
print(f"Patient zero: {report.patient_zero}")
Architecture
Security Alert → Alert Intake → IOC Extraction + Log Normalization (OCSF)
↓
Correlation Engine
↓
Attack Graph ← Timeline Engine → Risk Engine
↓
Incident Narrative Generator
↓
Markdown / JSON / HTML Reports
Core Modules
| Module | Description |
|---|---|
intake |
Alert ingestion (JSON, YAML, files) with deduplication |
ioc |
IOC extraction with regex pipelines and defanging |
normalization |
Log parsing (Sysmon, CrowdStrike, ECS, CloudTrail, etc.) → OCSF |
correlation |
Temporal and entity-based event correlation |
graph |
Attack graph construction and analysis (NetworkX) |
timeline |
Chronological attack reconstruction |
root_cause |
Patient zero and initial compromise analysis |
risk |
Evidence-based, explainable risk scoring |
mitre |
MITRE ATT&CK technique mapping |
narrative |
Analyst-friendly incident narratives with citations |
hunting |
Sigma, Splunk, Elastic, Sentinel, Wazuh query generation |
report |
Markdown, HTML, JSON export |
threat_intel |
Async enrichment (VirusTotal, AbuseIPDB, pluggable) |
plugins |
Extensible parser, enrichment, and exporter plugins |
Configuration
Create chronicle.yaml:
log_level: INFO
correlation_window_seconds: 3600
threat_intel:
virustotal:
enabled: true
api_key: "${VT_API_KEY}"
Plugin Development
Register plugins via entry points in pyproject.toml:
[project.entry-points."soc_chronicle.plugins"]
my_parser = "my_package:MyLogParser"
Implement LogParserPlugin, EnrichmentProviderPlugin, or ExporterPlugin from soc_chronicle.plugins.registry.
Development
pip install -e ".[dev]"
pytest
ruff check src tests
mypy src/soc_chronicle
mkdocs serve
Docker
docker build -t soc-chronicle .
docker run soc-chronicle investigate /app/examples/alert.json --logs /app/examples/logs
Design Principles
- Deterministic over probabilistic reasoning
- Explainable outputs backed by evidence
- Vendor-neutral architecture
- Plugin-based extensibility
- Offline-capable local processing
- Security-first design
License
Apache-2.0
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file soc_chronicle-0.1.0.tar.gz.
File metadata
- Download URL: soc_chronicle-0.1.0.tar.gz
- Upload date:
- Size: 51.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dca4bd58a79f55fa1479be8a8722f2841eb377b565bb978b3ed7abdd1f8b508c
|
|
| MD5 |
ec6b9ac6bf71290dfb8da6ed8ca8326d
|
|
| BLAKE2b-256 |
76572f92c865ced6e44ea2a7dcf6b3df771278dfb243c7d69e972356a53abe5d
|
File details
Details for the file soc_chronicle-0.1.0-py3-none-any.whl.
File metadata
- Download URL: soc_chronicle-0.1.0-py3-none-any.whl
- Upload date:
- Size: 64.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4c19a7b514fcf3da49fcc1b33b73e4846417d6f287a06fa984bac4e35ca8ac2c
|
|
| MD5 |
ada06ceb8421ca90a5b094c54a071d05
|
|
| BLAKE2b-256 |
b7f8837f8d53bdf34716451a938c669480b02049ff40e053cac87ddf095f6b1f
|