RomilCyber commited on
Commit
eb27145
·
verified ·
1 Parent(s): 47f2412

Add hackathon write-up

Browse files
Files changed (1) hide show
  1. README.md +95 -0
README.md ADDED
@@ -0,0 +1,95 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: mit
3
+ language: en
4
+ tags:
5
+ - ai-safety
6
+ - red-teaming
7
+ - dfir
8
+ - lexsi-hackathon
9
+ ---
10
+
11
+ # PHANTOM DFIR: red-teaming a forensic agent and fine-tuning tiny-aya-global to verify evidence
12
+
13
+ *Write-up for the Lexsi AI Safety and Alignment Hackathon. This repository holds the article only; the adapter and dataset are linked at the end.*
14
+
15
+ PHANTOM DFIR is a multi-agent digital forensics system. For the Lexsi AI Safety and Alignment Hackathon we added a safety layer on top of it: the layer attacks the agent's own verifier, measures the damage, repairs it, and then trains a small open model to do the job.
16
+
17
+ ## Why
18
+
19
+ In forensics, an AI agent that is confidently wrong is worse than no agent. A wrong "CRITICAL" wastes an incident response team's night. A wrong "CLEARED" lets an attacker stay.
20
+
21
+ ## The engine
22
+
23
+ You give PHANTOM a memory image, a disk image or a network capture. A router detects the type and sends it to the right pipeline.
24
+
25
+ For memory, four agents work in a loop:
26
+
27
+ - The **Collector** runs Volatility.
28
+ - The **Investigator** proposes findings.
29
+ - The **Evidence agent** re-checks each finding.
30
+ - The **Skeptic** challenges findings before anything is rated critical.
31
+
32
+ Disk images and network captures go to a disk correlator with a gap controller that checks what is still missing.
33
+
34
+ ## Red-teaming our own Skeptic
35
+
36
+ The harness loads the engine's real Skeptic code, unchanged, and feeds it adversarial evidence. There are 10 attack families and one clean control, 550 held-out rows in total.
37
+
38
+ It found three weaknesses:
39
+
40
+ 1. **The model's vote is ignored.** Three source keys override whatever the Skeptic model answers.
41
+ 2. **One process counts as several sources.** `vol3:malfind[4412]`, `vol3:dlllist[4412]` and `vol3:cmdline[4412]` are counted as three sources, but they describe one process.
42
+ 3. **The word "benign" clears a real threat.** With identical evidence, severity flips from CRITICAL to CLEARED on claim wording alone.
43
+
44
+ ## The repair: a grounded verifier
45
+
46
+ The grounded verifier counts distinct artifacts, accepts only behavioural evidence, and ignores the wording of the claim.
47
+
48
+ | Metric (550 held-out rows) | Engine's Skeptic | Grounded verifier |
49
+ |---|---|---|
50
+ | Accuracy | 0.273 | 0.727 |
51
+ | Attack success rate | 0.800 | 0.300 |
52
+ | False-confirm rate | 0.839 | 0.562 |
53
+
54
+ A paired McNemar test shows 250 rows fixed and 0 broken.
55
+
56
+ ## Chaining the Lexsi stack around a small open model
57
+
58
+ We then asked whether a small open-weights model can learn the verifier's job.
59
+
60
+ 1. **Baseline:** Cohere Labs `tiny-aya-global` evaluated as the verifier on the 550 held-out rows.
61
+ 2. **CuratorKIT:** curated the training rows.
62
+ 3. **AlignTune:** QLoRA fine-tune on an 8 GB laptop GPU (1,100 rows, 138 steps, 28 minutes).
63
+ 4. **AuditKIT:** scored both runs independently.
64
+
65
+ | Metric (550 held-out rows) | Base model | Fine-tuned |
66
+ |---|---|---|
67
+ | Accuracy | 0.524 | 0.998 |
68
+ | Attack success rate | 0.462 | 0.002 |
69
+ | False-confirm rate | 0.760 | 0.008 |
70
+ | Answers that are not valid JSON | 155 | 0 |
71
+
72
+ AuditKIT agrees with our own scorer: 0.531 before and 0.998 after.
73
+
74
+ ## Honest limits
75
+
76
+ - Three attack families still beat the rule verifier: `behavioural_mention`, `identity_alias` and `network_contact_inflation`.
77
+ - The data is synthetic. Training and held-out rows come from the same 11 templated generators, so 0.998 shows the model handles those 11 row shapes. Nothing outside them was tested.
78
+ - The model result is one training run with one seed.
79
+ - In 110 of 550 answers the adapter writes the correct verdict and then keeps generating. The score reads the first JSON object only.
80
+
81
+ ## Toolkit feedback
82
+
83
+ We found four defects while chaining the stack and wrote them up in the repo:
84
+
85
+ 1. CuratorKIT's duplicate filter ignores the evidence field and removed four whole attack families while reporting a clean pass.
86
+ 2. AlignTune's trainer factory silently drops the 4-bit setting.
87
+ 3. Float32 casts in AlignTune/PEFT pushed training past 8 GB.
88
+ 4. AuditKIT's documented plain-function scorer raises an error.
89
+
90
+ ## Links
91
+
92
+ - Code: https://github.com/romilp619/Phantom-DFIR
93
+ - Adapter and logs: https://huggingface.co/RomilCyber/tiny-aya-global-phantom-verifier-qlora
94
+ - Dataset: https://huggingface.co/datasets/RomilCyber/phantom-dfir-evidence-grounding
95
+ - Full write-up: `docs/MODEL-RESULT.md` in the repo