# clong/detectionlab architecture

> Architecture diagram of the GitHub repository clong/detectionlab, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-19). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/clong/detectionlab
- Repository: https://github.com/clong/detectionlab

## Overview

DetectionLab is a deliberately insecure, defender-focused Windows-domain lab. Users choose a local or supported infrastructure deployment, build the lab, and receive a domain preloaded with endpoint, network, and logging visibility tooling. The README documents the capabilities and selected host placements, but no source excerpts were provided; deployment internals and undocumented component-to-component flows are therefore omitted. The diagram preserves documented deployment choices and major product capabilities rather than implying a single provisioning pipeline.

Main entry points: [`Vagrant/resources`](https://github.com/clong/detectionlab/tree/master/Vagrant/resources) (Windows hosts), [`Vagrant/resources/osquery`](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/osquery) (osquery and Fleet), [`Vagrant/resources/microsoft_ata`](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/microsoft_ata) (Advanced Threat Analytics), [`Vagrant/resources/GPO`](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/GPO) (Auditing policies)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_deployment["Lab deployment"]
  node_local["Vagrant deployment"]
  node_aws["AWS deployment"]
  node_azure["Azure deployment"]
  node_azure_ansible["Azure configuration"]
  node_esxi["ESXi deployment<br/>[main.tf]"]
  node_proxmox["Proxmox deployment"]
  node_hyperv["Hyper-V deployment"]
  node_packer["Windows images<br/>[windows_10.json]"]
end

subgraph group_domain["Windows domain"]
  node_dc["Domain controller"]
  node_wef["WEF server"]
  node_windows_hosts["Windows hosts"]
  node_gpo["Auditing policies"]
end

subgraph group_telemetry["Host telemetry"]
  node_ata["Advanced Threat Analytics"]
  node_splunk["Splunk collection"]
  node_osquery["osquery and Fleet"]
  node_fleet["Fleet server"]
  node_wef_config["Event forwarding"]
end

subgraph group_analysis["Network and analysis"]
  node_zeek["Zeek monitoring"]
  node_suricata["Suricata monitoring"]
end

subgraph group_access["Lab access"]
  node_guacamole["Browser access"]
end

node_user(("Lab builder"))
node_browser(("Local browser"))

node_user -->|"builds locally"| node_local
node_user -->|"deploys via"| node_aws
node_user -->|"deploys via"| node_azure
node_user -->|"configures via"| node_azure_ansible
node_user -->|"deploys via"| node_esxi
node_user -->|"deploys via"| node_proxmox
node_user -->|"deploys via"| node_hyperv
node_user -.->|"builds lab"| node_packer
node_wef -->|"hosts"| node_ata
node_dc -->|"hosts gateway"| node_ata
node_splunk -.->|"forwards logs"| node_wef
node_osquery -->|"connects to"| node_fleet
node_windows_hosts -->|"runs on"| node_osquery
node_gpo -->|"configures auditing"| node_windows_hosts
node_wef_config -->|"configures forwarding"| node_wef
node_zeek -.->|"monitors traffic"| node_windows_hosts
node_suricata -.->|"monitors traffic"| node_windows_hosts
node_browser -->|"accesses hosts"| node_guacamole

click node_local "https://github.com/clong/detectionlab/blob/master/Vagrant/Vagrantfile"
click node_aws "https://github.com/clong/detectionlab/tree/master/AWS/Terraform"
click node_azure "https://github.com/clong/detectionlab/tree/master/Azure/Terraform"
click node_azure_ansible "https://github.com/clong/detectionlab/tree/master/Azure/Ansible"
click node_esxi "https://github.com/clong/detectionlab/blob/master/ESXi/main.tf"
click node_proxmox "https://github.com/clong/detectionlab/tree/master/Proxmox/Terraform"
click node_hyperv "https://github.com/clong/detectionlab/blob/master/HyperV/Vagrantfile"
click node_packer "https://github.com/clong/detectionlab/blob/master/Packer/windows_10.json"
click node_dc "https://github.com/clong/detectionlab/tree/master/Vagrant/resources"
click node_wef "https://github.com/clong/detectionlab/tree/master/Vagrant/resources"
click node_windows_hosts "https://github.com/clong/detectionlab/tree/master/Vagrant/resources"
click node_gpo "https://github.com/clong/detectionlab/tree/master/Vagrant/resources/GPO"
click node_ata "https://github.com/clong/detectionlab/tree/master/Vagrant/resources/microsoft_ata"
click node_splunk "https://github.com/clong/detectionlab/tree/master/Vagrant/resources/splunk_forwarder"
click node_osquery "https://github.com/clong/detectionlab/tree/master/Vagrant/resources/osquery"
click node_fleet "https://github.com/clong/detectionlab/tree/master/Vagrant/resources/fleet"
click node_wef_config "https://github.com/clong/detectionlab/tree/master/Vagrant/resources/GPO/wef_configuration"
click node_zeek "https://github.com/clong/detectionlab/tree/master/Vagrant/resources/zeek"
click node_suricata "https://github.com/clong/detectionlab/tree/master/Vagrant/resources/suricata"
click node_guacamole "https://github.com/clong/detectionlab/tree/master/Vagrant/resources/guacamole"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_local,node_aws,node_azure,node_azure_ansible,node_esxi,node_proxmox,node_hyperv,node_packer,node_browser toneBlue
class node_dc,node_wef,node_windows_hosts,node_gpo toneAmber
class node_ata,node_splunk,node_osquery,node_fleet,node_wef_config toneMint
class node_zeek,node_suricata toneRose
class node_guacamole,node_user toneIndigo
```

## Components

### Lab deployment

- [Vagrant deployment](https://github.com/clong/detectionlab/blob/master/Vagrant/Vagrantfile): `Vagrant/Vagrantfile`
- [AWS deployment](https://github.com/clong/detectionlab/tree/master/AWS/Terraform): `AWS/Terraform`
- [Azure deployment](https://github.com/clong/detectionlab/tree/master/Azure/Terraform): `Azure/Terraform`
- [Azure configuration](https://github.com/clong/detectionlab/tree/master/Azure/Ansible): `Azure/Ansible`
- [ESXi deployment](https://github.com/clong/detectionlab/blob/master/ESXi/main.tf): `ESXi/main.tf`
- [Proxmox deployment](https://github.com/clong/detectionlab/tree/master/Proxmox/Terraform): `Proxmox/Terraform`
- [Hyper-V deployment](https://github.com/clong/detectionlab/blob/master/HyperV/Vagrantfile): `HyperV/Vagrantfile`
- [Windows images](https://github.com/clong/detectionlab/blob/master/Packer/windows_10.json): `Packer/windows_10.json`

### Windows domain

- [Domain controller](https://github.com/clong/detectionlab/tree/master/Vagrant/resources): `Vagrant/resources`
- [WEF server](https://github.com/clong/detectionlab/tree/master/Vagrant/resources): `Vagrant/resources`
- [Windows hosts](https://github.com/clong/detectionlab/tree/master/Vagrant/resources): `Vagrant/resources`
- [Auditing policies](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/GPO): `Vagrant/resources/GPO`

### Host telemetry

- [Advanced Threat Analytics](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/microsoft_ata): `Vagrant/resources/microsoft_ata`
- [Splunk collection](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/splunk_forwarder): `Vagrant/resources/splunk_forwarder`
- [osquery and Fleet](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/osquery): `Vagrant/resources/osquery`
- [Fleet server](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/fleet): `Vagrant/resources/fleet`
- [Event forwarding](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/GPO/wef_configuration): `Vagrant/resources/GPO/wef_configuration`

### Network and analysis

- [Zeek monitoring](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/zeek): `Vagrant/resources/zeek`
- [Suricata monitoring](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/suricata): `Vagrant/resources/suricata`

### Lab access

- [Browser access](https://github.com/clong/detectionlab/tree/master/Vagrant/resources/guacamole): `Vagrant/resources/guacamole`

### Other components

- **Lab builder**
- **Local browser**

## Connections

- Lab builder → Vagrant deployment: builds locally (evidence: `README.md`)
- Lab builder → AWS deployment: deploys via (evidence: `README.md`)
- Lab builder → Azure deployment: deploys via (evidence: `README.md`)
- Lab builder → Azure configuration: configures via (evidence: `README.md`)
- Lab builder → ESXi deployment: deploys via (evidence: `README.md`)
- Lab builder → Proxmox deployment: deploys via (evidence: `README.md`)
- Lab builder → Hyper-V deployment: deploys via (evidence: `README.md`)
- Lab builder → Windows images: builds lab
- WEF server → Advanced Threat Analytics: hosts (evidence: `README.md`)
- Domain controller → Advanced Threat Analytics: hosts gateway (evidence: `README.md`)
- Splunk collection → WEF server: forwards logs
- osquery and Fleet → Fleet server: connects to (evidence: `README.md`)
- Windows hosts → osquery and Fleet: runs on (evidence: `README.md`)
- Auditing policies → Windows hosts: configures auditing (evidence: `README.md`)
- Event forwarding → WEF server: configures forwarding (evidence: `README.md`)
- Zeek monitoring → Windows hosts: monitors traffic
- Suricata monitoring → Windows hosts: monitors traffic
- Local browser → Browser access: accesses hosts (evidence: `README.md`)
