The most common failure mode in detection programs isn’t bad rules — it’s untested rules. Rules that look correct in YAML but fail silently in production because of a field mapping gap, a missing telemetry source, or a SIEM configuration mismatch. Adversary emulation closes this gap by running the actual attack behavior and checking if the alarm goes off.
The Validation Gap
Detection engineering has two halves:
Half 1: Author Half 2: Validate
───────────────────── ──────────────────────────────
Write Sigma rule → Run the attack in a test lab
Convert to SIEM query → Confirm the alert fires
Add to SIEM library → Verify telemetry is present
Write the ADS → Test FP exclusions don't suppress TPs
Most detection programs invest heavily in Half 1 and almost nothing in Half 2. The result: a detection library full of rules with unknown firing status. Some fire correctly. Some fire but with high FP rates. Some never fire at all — because the environment is missing a precondition the rule author assumed.
The Three Silent Failure Modes
Failure Mode 1: Missing Telemetry
A rule for Sysmon Event 10 (LSASS access) does nothing if:
- Sysmon isn’t installed on the servers where credential dumping typically occurs
- The Sysmon config excludes the event types the rule needs
- The endpoint agent collects Sysmon events but only from workstations, not servers
Emulation test reveals this immediately: run the test on a server, check the SIEM — zero events. The gap is visible.
Failure Mode 2: Field Mapping Gap
A Sigma rule uses OriginalFileName to detect renamed binaries. The field is valid in the Sysmon spec. But:
- Your Splunk pipeline maps Sysmon Event 1 fields but never added
OriginalFileNameto the mapping - sigma-cli silently drops unmapped fields during conversion
- The converted SPL query checks
Imagebut has noOriginalFileNamecondition - A renamed mimikatz.exe passes straight through
Emulation test reveals this: run the test, check the SIEM, find an alert — but inspect the query. The OriginalFileName condition is absent. Coverage is weaker than the rule implies.
Failure Mode 3: Logsource Mismatch
A rule targets logsource: category: process_creation, product: windows. Your SIEM indexes Sysmon data under index=sysmon but the pipeline converts the rule to query index=windows. Different index — no results.
Or: the rule was written for Sysmon but your environment uses the Windows Security provider (4688). Different event structure — conditions that reference Sysmon-specific fields like ProcessGuid return nothing.
Emulation vs Penetration Testing vs Red Teaming
| Emulation | Pen Test | Red Team | |
|---|---|---|---|
| Goal | Validate detections | Find vulnerabilities | Test full defense |
| Who controls it | Detection engineer | Security team | Red team + blue team |
| Scope | Specific ATT&CK techniques | System attack surface | Full kill chain |
| Environment | Isolated test lab | Target network (scoped) | Production (authorized) |
| Output | Coverage matrix + detection gaps | Vuln report + remediation | TTX findings + MTTD |
| Risk | Very low (isolated) | Low-medium | Highest |
Detection engineers run emulation — controlled, scoped, in a lab. Pen testing and red teaming are broader and require more organizational coordination. Don’t conflate them.
DetectionLab: A Ready-Made Test Environment
DetectionLab (github.com/clong/DetectionLab) provisions a complete Windows detection lab:
DC (dc.windomain.local) ← Domain Controller, Windows Server 2019
WEF (wef.windomain.local) ← Windows Event Forwarder
Win10 (win10.windomain.local) ← Client workstation
Logger (logger.windomain.local) ← Splunk + ELK
Pre-installed on all Windows hosts:
- Sysmon (SwiftOnSecurity config)
- Winlogbeat (ships events to Logger)
- Osquery
- velociraptor (optional)
Pre-installed on Logger:
- Splunk Enterprise (trial)
- Elastic + Kibana
Build time: 30–60 minutes with Vagrant + VirtualBox.
Lighter alternative: Single Windows 10 VM + Sysmon (from sysmon.xml config) + Winlogbeat → free Elastic Cloud trial.
The Emulation Workflow
1. Choose technique
→ Pick ATT&CK technique to test (e.g., T1003.001)
→ Confirm you have a detection rule for it
2. Prepare the test environment
→ Verify Sysmon is running and generating events
→ Confirm events are flowing to the SIEM (check count)
→ Document the environment state
3. Run the emulation test
→ Execute the atomic test / CALDERA operation
→ Note exact execution time
4. Query the SIEM
→ Search for events in ±5 minute window around execution time
→ Check raw events: are the fields populated?
→ Check alert: did the detection rule fire?
5. Record the outcome
→ FIRE: rule fired correctly → mark as "Covered"
→ NO FIRE + events present: rule logic or mapping issue → mark as "Miscovered"
→ NO FIRE + no events: telemetry gap → mark as "Gap"
6. Remediate and retest
→ Fix the identified issue (deploy Sysmon, fix field mapping, fix rule logic)
→ Re-run the test to confirm the fix works
DetectionLab— GitHub
Atomic Red Team— Red Canary