Talus โ Userspace TUI
Overviewโ
The userspace component reads eBPF events from perf buffers, maintains process state, runs the ransomware heuristic, and renders a real-time terminal UI.
Event Pipelineโ
โโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโ
โ PerfBuffer โโโโโโบโ Deserialise โโโโโโบโ Tracker โ
โ (async read)โ โ (bincode) โ โ (PID map) โ
โโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโ โโโโโโโโฌโโโโโโโโ
โ
โโโโโโโโผโโโโโโโโ
โ Heuristic โ
โ (sliding) โ
โโโโโโโโฌโโโโโโโโ
โ
โโโโโโโโผโโโโโโโโ
โ TUI Render โ
โ (frankentui)โ
โโโโโโโโโโโโโโโโ
Process Trackerโ
Maintains a bounded map of active processes:
struct ProcessInfo {
pid: u32,
ppid: u32,
name: String,
start_time: u64,
file_ops: u64, // total file operations
renames: u64, // rename count in window
last_activity: u64, // last event timestamp
}
- PID โ ProcessInfo map with LRU eviction
- Process tree construction from PPID chains
- Zombie cleanup on process exit
Ransomware Heuristicโ
Sliding-window analysis (default: 60-second window):
Signals Monitoredโ
- Rename velocity โ file renames per second per process
- Entropy delta โ Shannon entropy change in file contents
- Extension mass-change โ .doc โ .locked, .jpg โ .enc, etc.
- Write-after-rename โ write to file immediately after rename
Scoringโ
Each signal contributes to a confidence score:
- Rename velocity > 10/s โ +0.3
- Entropy increase > 2.0 bits โ +0.3
- Known ransomware extension โ +0.4
- Combined score > 0.7 โ ALERT
Alert Outputโ
When triggered, the TUI shows:
- Process name, PID, PPID
- Full process tree (who spawned it)
- File operations in the last 60 seconds
- Entropy profile of modified files
TUI Layoutโ
โโ Talus eBPF Monitor โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ Process Tree โ File Operations โ Alerts โ
โ โโ systemd (1) โ /etc/passwd READ โ โ
โ โ โโ sshd (1234) โ /var/log/auth WRITE โ โ
โ โ โโ bash (5678) โ doc.pdf RENAME โ โ
โ โ โโ vim (9012) โ doc.locked WRITE โ โ ALERT โ
โ โ โ โ suspicion โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Keyboard Controlsโ
| Key | Action |
|---|---|
q | Quit |
Tab | Switch panel focus |
โโ | Navigate process tree |
Enter | Expand/collapse process |
/ | Search process name |
1/2/3 | Filter: all / processes / file ops |