ScanPipeline in src/pipeline/mod.rs.
Pipeline Overview
Every scan follows this progression:Stage Architecture
Each stage is implemented as a self-contained module:src/pipeline/mod.rs
Each stage produces artifacts that downstream stages consume. For example, the Tyr threat model guides the Hunt agent’s investigations.
Monitoring Progress
Heimdall provides real-time visibility into scan execution through multiple channels:Server-Sent Events (SSE)
Connect to the SSE endpoint to receive live updates:Scan Events Table
Query thescan_events table for a complete audit trail:
Stage Status Tracking
Each stage records detailed status in thescan_stages table:
| Field | Description |
|---|---|
stage | Stage name (e.g., hunt, tyr, garmr) |
status | Current status: pending, running, completed, failed |
started_at | Timestamp when execution began |
completed_at | Timestamp when execution finished |
error_message | Failure reason if status is failed |
Expected Timeframes
Scan duration varies based on repository size and complexity:Small Repositories (< 10k LOC)
Small Repositories (< 10k LOC)
Total Duration: 2-5 minutes
- Ingest: 10-20 seconds
- Tyr: 30-60 seconds
- Static Analysis: 20-40 seconds
- Hunt: 1-2 minutes
- Garmr: 30-60 seconds
- Report: 20-30 seconds
Medium Repositories (10k-100k LOC)
Medium Repositories (10k-100k LOC)
Total Duration: 5-15 minutes
- Ingest: 30-90 seconds
- Tyr: 60-120 seconds
- Static Analysis: 1-3 minutes
- Hunt: 3-8 minutes
- Garmr: 1-2 minutes
- Report: 30-60 seconds
Large Repositories (> 100k LOC)
Large Repositories (> 100k LOC)
Total Duration: 15-45 minutes
- Ingest: 2-5 minutes
- Tyr: 2-4 minutes
- Static Analysis: 3-8 minutes
- Hunt: 8-25 minutes (parallel investigations)
- Garmr: 2-5 minutes
- Report: 1-2 minutes
Error Handling
The pipeline implements robust error handling with graceful degradation:src/pipeline/mod.rs
If a stage fails, the pipeline halts and marks the scan as
failed. The error message is captured in both scan_stages.error_message and scans.error_message.Cancellation Support
Users can cancel running scans at any time:src/pipeline/mod.rs
Next Steps
Hunt Agent
Learn how the agentic discovery engine works
Threat Modeling
Understand Tyr’s STRIDE-based analysis
Sandbox Validation
See how Garmr validates exploitability
Findings Management
Manage and remediate vulnerabilities