amareshhebbar/AllBlue
GitHub: amareshhebbar/AllBlue
AllBlue 是一个自主多 Agent DFIR 编排系统,由 Splunk 告警触发 AI 自动取证分流,实现端到端自动化安全调查闭环。
Stars: 0 | Forks: 0
```
█████╗ ██╗ ██╗ ██████╗ ██╗ ██╗ ██╗███████╗
██╔══██╗██║ ██║ ██╔══██╗██║ ██║ ██║██╔════╝
███████║██║ ██║ ██████╔╝██║ ██║ ██║█████╗
██╔══██║██║ ██║ ██╔══██╗██║ ██║ ██║██╔══╝
██║ ██║███████╗███████╗██████╔╝███████╗╚██████╔╝███████╗
╚═╝ ╚═╝╚══════╝╚══════╝╚═════╝ ╚══════╝ ╚═════╝ ╚══════╝
```
**自主多 Agent DFIR 编排器 × Splunk**
Splunk 告警触发自主取证分流 → 将发现结果作为结构化 IOC 事件推送到 Splunk → 实时 DFIR 情报仪表板。
[](https://github.com/amareshhebbar/allblue/commits/main)
[](https://github.com/amareshhebbar/allblue)
[](https://splunk.devpost.com)
[]()
[]()
[]()
[](LICENSE)
[架构](docs/architecture.md) · [准确率报告](docs/accuracy_report.md) · [数据集](docs/dataset.md) · [问题](https://github.com/amareshhebbar/allblue/issues) · [分流结果](TRIAGE_RESULT.md)
## 什么是 AllBlue
AllBlue 是一个自主的 DFIR 分流系统,它通过**使用 Go 编写的自定义 MCP Server**(具有 Gemini 故障转移功能)将 Claude 连接到工具链 —— 现已与 **Splunk** 全面集成,Splunk 同时用作触发源和发现结果的目标。
**核心设计原则:** LLM 不能运行 shell 命令。它只能调用带类型的 Go 函数。MCP server 就是安全边界 —— 这是架构上的强制执行,而不是基于提示词的规则。
**Splunk 集成:** Splunk 告警会自动触发 AllBlue 分流会话。所有发现的结果都会通过 HEC 作为结构化事件推送回 Splunk。在分流过程中会查询 Splunk MCP Server,以利用历史上下文来丰富发现的结果。
已在 SRL-2018 APT 数据集(包含 DKOM rootkit、C2 beaconing 和横向移动的真实世界入侵)上进行了验证:
- 识别出 **14 个已记录 IOC 中的 13 个** —— C2 IP,所有恶意进程,rootkit 已确认
- **100% 准确率** —— 零幻觉发现
- **6 次 agentic 迭代**,具有自主检测隐藏 DKOM rootkit 的自我纠正能力
## Splunk 集成的工作原理
```
1. Splunk Alert fires → POST webhook to AllBlue :8718/splunk-alert
2. AllBlue launches → autonomous multi-agent DFIR triage
3. Agents query → Splunk MCP Server for IP/process enrichment
4. Findings pushed → Splunk HEC as allblue:ioc events
5. Dashboard shows → live IOCs, threat scores, session logs
```
- **安全类最佳奖** — $3,000
- **Splunk MCP Server 最佳应用奖** — $1,000 奖金
- **大奖** — $7,000
## 快速开始
```
# 克隆
git clone https://github.com/amareshhebbar/allblue
cd allblue
# 配置
cp .example.env .env
# 编辑 .env — 添加你的 keys:
# ANTHROPIC_API_KEY=sk-ant-...
# SPLUNK_HEC_TOKEN=xxxx-xxxx-xxxx-xxxx
# SPLUNK_HEC_URL=http://localhost:8088
# SPLUNK_MCP_URL=http://localhost:3000
# 构建
go mod tidy
go build -o allblue-ai ./cmd/sift-mcp/
# 运行 — 启动 MCP server + Splunk webhook receiver
./allblue-ai --mode=mcp
# 使用 Splunk push 运行自主 triage
./allblue-ai --mode=ai \
--target=/path/to/evidence.img \
--type=memory \
--splunk-push=true
```
### 运行基准测试
```
7z x /path/to/base-hunt-memory.7z -o/tmp/evidence/
chmod +x benchmark/run_benchmark.sh
./benchmark/run_benchmark.sh /tmp/evidence/base-hunt-memory.img memory
```
预期输出:
```
True Positives (TP): 13
False Negatives (FN): 1
False Positives (FP): 0
Precision: 100.00%
Recall: 92.86%
```
## 架构

```
Claude/Gemini (LLM)
│ MCP calls only — no shell access
▼
cmd/sift-mcp/main.go ← SECURITY BOUNDARY
│ 15 typed MCP tools (12 original + 3 new Splunk tools)
│
┌────┴────────────────────┐
│ │
agents/ internal/
│ │
├─ orchestrator ├─ wrappers/ (7 typed tool wrappers)
├─ memory_agent ├─ validator/ (CONFIRMED/INFERRED/UNVERIFIED)
├─ disk_agent ├─ correlator/ (disk vs memory cross-ref)
└─ reasoning_logger ├─ registry/ (tool allowlist, 30+ entries)
└─ splunk/ ← NEW
├─ hec.go (push findings to Splunk)
├─ mcp_client.go (query Splunk MCP Server)
└─ alert_handler.go(receive Splunk webhooks)
│
SIFT Tools (read-only)
vol / fls / log2timeline / rip.pl / yara / hashdeep
│
Splunk HEC → index=main → Dashboard
```
[完整的架构文档 →](docs/architecture.md)
## MCP 工具(已注册 15 个)
### 原始 DFIR 工具 (12)
| 工具 | 类别 | 功能 |
|---|---|---|
| `analyze_memory_windows_info` | 内存 | OS 版本、内核基址、架构 |
| `analyze_memory_pslist` | 内存 | 通过池标签进行进程扫描(绕过 DKOM) |
| `analyze_memory_netscan` | 内存 | 活动 + 已关闭的 TCP/UDP 连接 |
| `analyze_memory_malfind` | 内存 | 代码注入、进程空洞化(process hollowing) |
| `analyze_memory_cmdline` | 内存 | 所有进程的命令行参数 |
| `hunt_memory_malware` | 内存 | **具有自我纠正功能的完整自主 9 步分流** |
| `analyze_disk_timeline` | 磁盘 | log2timeline → psort 超级时间线 |
| `analyze_disk_fls` | 磁盘 | 文件系统列表(已分配 + 已删除) |
| `analyze_registry` | 注册表 | SAM/SYSTEM/SOFTWARE/NTUSER 配置单元提取 |
| `run_yara_scan` | 检测 | 使用 8 条内置 APT 规则进行模式匹配 |
| `verify_hashes` | 完整性 | 计算 SHA-256/MD5 或根据已知正常值进行审计 |
| `correlate_findings` | 分析 | 内存 ↔ 磁盘交叉引用,无文件/时间戳(timestomp)检测 |
### 新增 Splunk 工具 (3)
| 工具 | 文件 | 功能 |
|---|---|---|
| `push_findings_to_splunk` | `internal/splunk/hec.go` | 将所有 IOC 发现结果作为结构化事件发送到 Splunk HEC |
| `query_splunk_alerts` | `internal/splunk/mcp_client.go` | 查询 Splunk MCP Server 以获取最近的安全告警 |
| `get_splunk_context` | `internal/splunk/mcp_client.go` | 利用历史 Splunk 数据(IP/进程)丰富发现结果 |
## 证据与结果
| 文档 | 描述 |
|---|---|
| [截图 →](docs/SCREENSHOTS.md) | 5 张带注释的截图:安全边界、APT 发现、自我纠正、基准测试、审计追踪 |
| [演示视频 →](docs/VIDEO.md) | 带有解说的录屏 —— 针对 SRL-2018 APT 证据的实时分流 |
| [实时结果 →](docs/RESULT.md) | 实际分流运行的完整输出 —— 进程发现、C2 连接、rootkit 检测 |
## 自我纠正演示
内存 agent 的自我纠正序列(可在终端输出中查看):
```
[*] Claude iteration 3/10
-> Tool: hunt_memory_malware
[MemoryAgent] Starting autonomous memory triage...
~ [MemoryAgent] vol_windows_info | 805ms | INFERRED
~ [MemoryAgent] vol_windows_pslist | 31s | INFERRED
↳ DELTA: pslist returned only header — rootkit DKOM confirmed
~ [MemoryAgent] analyze_memory_netscan| 30s | INFERRED
✓ [MemoryAgent] vol_windows_malfind | 882ms | CONFIRMED
↳ DELTA: Empty malfind on 90+ process system = VAD hook = rootkit IOC
✓ [MemoryAgent] vol_windows_cmdline | 890ms | CONFIRMED
↳ DELTA: Empty cmdline = process args hidden by rootkit
~ [MemoryAgent] vol_windows_svcscan | 1.2s | INFERRED
✓ [MemoryAgent] psxview_diff | 2.1s | CONFIRMED
↳ DELTA: DKOM confirmed — 87 processes hidden from pslist, visible in psscan
```
## 证据完整性
所有操作均通过架构强制执行保持为**只读**:
- 调用 Volatility 时使用了 `-f path` —— 只读文件访问
- TSK 工具在设计上就是只读的
- 工具注册表中没有写入、删除或修改操作
- `exec.Command("vol", args...)` —— 绝不使用 `exec.Command("bash", "-c", input)`
- 在分流开始时计算 SHA-256 + MD5,并在结束时进行验证
- 破坏测试:完整分流前后的哈希值 —— 完全一致
## 项目结构
```
allblue/
├── cmd/sift-mcp/main.go # MCP server — 15 typed tools registered
├── agents/
│ ├── orchestrator/
│ │ ├── orchestrator.go # Claude/Gemini dual engine, 10-iteration loop
│ │ └── findings_extractor.go # Pre-triage Go parser
│ ├── memory_agent/memory.go # 9-step autonomous memory triage
│ ├── disk_agent/disk.go # Disk triage, log2timeline pipeline
│ └── reasoning_logger/reasoning_logger.go # Intent/hypothesis/delta audit per call
├── internal/
│ ├── wrappers/ # 7 typed tool wrappers (no raw shell)
│ │ ├── volatility.go
│ │ ├── regripper.go
│ │ ├── tsk.go
│ │ ├── bulk_extractor.go
│ │ ├── foremost.go
│ │ ├── log2timeline.go
│ │ ├── yara.go
│ │ ├── hashdeep.go
│ │ ├── dynamic.go
│ │ ├── executor.go # SafeExec — never bash -c
│ │ └── helpers.go
│ ├── splunk/ # ← NEW for Splunk hackathon
│ │ ├── hec.go # Push findings to Splunk HEC
│ │ ├── mcp_client.go # Query Splunk MCP Server
│ │ └── alert_handler.go # Receive Splunk webhook alerts
│ ├── registry/sift_tools.go # 30+ tool allowlist
│ ├── validator/validator.go # Hallucination guard
│ ├── correlator/correlator.go # Disk vs memory cross-ref
│ ├── logger/logger.go # JSONL audit trail
│ └── parsers/
│ ├── plaso_parser.go
│ └── vol_parser.go
├── splunk/ # ← NEW
│ ├── dashboard.xml # Import into Splunk UI
│ └── saved_search.conf # Alert configs
├── benchmark/
│ ├── run_benchmark.sh
│ ├── ground_truth/srl2018_apt_ground_truth.json
│ └── results/
├── docs/
│ ├── architecture.md # Full architecture + diagram
│ ├── architecture.png # Architecture diagram (PNG)
│ ├── accuracy_report.md
│ ├── dataset.md
│ ├── devpost_story.md
│ ├── SCREENSHOTS.md
│ ├── VIDEO.md
│ └── RESULT.md
├── .example.env
├── go.mod
├── go.sum
└── README.md
```
## 准确率结果
完整报告:[docs/accuracy_report.md](docs/accuracy_report.md)
基于 SRL-2018 受损企业网络(DFIR Summit 数据集)进行测试:
| 指标 | 结果 |
|---|---|
| 真阳性 | 13 / 14 个 IOC |
| 假阳性 | 0 |
| 幻觉 | 0 |
| 准确率 | **100%** |
| 召回率 | **92.8%** |
| 分流时间 | 552 秒 |
## 许可证
MIT — 详见 [LICENSE](LICENSE)
## 构建于
[Splunk Agentic Ops 黑客松](https://splunk.devpost.com) — 安全赛道 · 2026 年 6 月
最初为 [SPLUNK! 黑客松](https://splunk.devpost.com/) 开发 — 思科公司 · 2026 年 4 月–6 月标签:AI告警分诊, DFIR自动化, EVTX分析, Go语言, PB级数据处理, 多智能体, 安全运维, 日志审计, 程序破解