LAB HUB

Docker cyber range

A portable, isolated range that runs on one laptop or an approved cloud sandbox. Six segmented networks model a realistic IT + OT enterprise. Every target stays inside the range.

Network segmentation diagram — click a zone to filter
→
⇄ broker

Allowed flows: external → proxy only; corp-user → server-net via proxy; sec-mgmt collects logs from all; IT reaches OT only through the IDMZ. Direct corp-user → ot-control is always blocked.

ContainerRoleSegmentImagePort bindingCPURAMNotes
student-wsStudent workstationcorp-usertraining/student-ws:latest127.0.0.1:6080→6080 (noVNC)1.01gTools & browser; entry point for exercises.
proxyReverse proxycorp-usernginx:alpine127.0.0.1:8443→4430.25256mFront-ends web services; TLS practice.
linux-srvLinux serverserver-netdebian:stable-sliminternal only0.5512mGeneral services host.
webappWeb applicationserver-netbkimminich/juice-shop127.0.0.1:3000→30001.01gVulnerable training app (e.g., Juice Shop) — isolated only.
api-svcAPI serviceserver-nettraining/api-svc:latest127.0.0.1:8081→80800.5512mREST API target for API-security labs.
dbDatabaseserver-netpostgres:16-alpineinternal only0.5512mSynthetic data only; no real records.
dnsDNS serviceserver-netinternetsystemsconsortium/bind9internal 53/udp0.25256mName resolution for the range.
log-srvLogging serversec-mgmttraining/rsyslog:latestinternal 514/udp0.5512mCentral log collector.
siemSIEM / log analysissec-mgmttraining/siem:latest127.0.0.1:5601→56012.04gDetection & hunting (training build).
sensorNetwork-monitoring sensorsec-mgmttraining/suricata:latestinternal only1.01gTraffic capture / IDS training.
idpIdentity / auth servicesec-mgmttraining/idp:latest127.0.0.1:8080→80800.51gDirectory / SSO simulation.
jumpSecure jump serversec-mgmttraining/jump:latest127.0.0.1:2222→220.25256mControlled access to sensitive segments.
historianHistorian (optional)idmztraining/historian:latestinternal only0.5512mTime-series data store for OT labs.
plc-simPLC / process simulatorot-controltraining/openplc:latestinternal 502/tcp0.5512mSimulated industrial process — never a real one.
hmi-simHMI simulatorot-controltraining/hmi:latest127.0.0.1:8090→80800.5512mOperator interface simulation.
attackerSimulated attacker workstationexternalkalilinux/kali-rollingnone (exec in)1.02gKali-style toolset; range-internal only.
Host requirements
CPU
Min: 4 cores · Rec: 8 cores
RAM
Min: 8 GB · Rec: 16 GB
Disk
Min: 40 GB free · Rec: 80 GB free
Host OS
Min: Windows 10/11 + WSL2, macOS 12+, or Linux · Rec: Linux or macOS for OT labs
Software
Min: Docker Engine 24+ with Compose v2 · Rec: Docker Desktop latest
Subnets: corp-user 172.30.10.0/24 · server-net 172.30.20.0/24 · sec-mgmt 172.30.30.0/24 · idmz 172.30.40.0/24 · ot-control 172.30.50.0/24 · external 172.30.90.0/24
Student startup guide
  1. 1Confirm Docker Engine 24+ and Compose v2 are installed and the host has 16 GB RAM free.
  2. 2Confirm the host is NOT on a production network; the range must be isolated.
  3. 3Clone the range folder and review docker-compose.yml before starting anything.
  4. 4Start the IT half first: `docker compose --profile it up -d`.
  5. 5Verify health: `docker compose ps` — every service reports healthy.
  6. 6Start the OT half only when the week calls for it: `docker compose --profile ot up -d`.
  7. 7Snapshot a clean state before the exercise begins.
  8. 8At the end of class run the reset: `docker compose down -v`.
Safety & portability controls
  • Vulnerable applications run only inside the isolated range.
  • Bind services to localhost wherever practical; disable unnecessary external exposure.
  • No real credentials, personal information, production data, or active malware.
  • Synthetic user accounts and synthetic data only.
  • Health checks, central logging, and a documented reset script for a clean state.
  • Snapshot-and-recovery procedure documented; Windows, macOS and Linux guidance included.
  • Offline classroom deployment and approved cloud-sandbox deployment both supported.
Reset procedure
docker compose down -v
docker compose --profile it up -d
docker compose ps
Compose reference skeleton
# G3 Cyber Range - reference skeleton (training use, isolated networks only)
name: g3-cyber-range

networks:
  corp-user:  { driver: bridge, internal: true }
  server-net: { driver: bridge, internal: true }
  sec-mgmt:   { driver: bridge, internal: true }
  idmz:       { driver: bridge, internal: true }
  ot-control: { driver: bridge, internal: true }
  external:   { driver: bridge, internal: true }

volumes:
  db-data:
  log-data:
  siem-data:

x-hardening: &hardening
  security_opt: ["no-new-privileges:true"]
  restart: unless-stopped

services:
  student-ws:
    <<: *hardening
    image: training/student-ws:latest
    networks: [corp-user]
    ports: ["127.0.0.1:6080:6080"]
    profiles: ["it"]
    healthcheck:
      test: ["CMD", "true"]
      interval: 30s

  webapp:
    <<: *hardening
    image: bkimminich/juice-shop
    networks: [server-net]
    ports: ["127.0.0.1:3000:3000"]
    profiles: ["it"]

  plc-sim:
    <<: *hardening
    image: training/openplc:latest
    networks: [ot-control]
    profiles: ["ot"]
    # Simulation only. Never connect this service to real equipment.

16-step Docker lab progression

L1Launching, stopping, inspecting and resetting containers
Week 1

Objective: Operate the range safely from a clean state.

Bring up student-ws, stop it, inspect it, then reset the range and confirm a clean state.

L2Images, containers, networks, ports and volumes
Week 2

Objective: Distinguish the five core Docker objects.

List images, containers, networks and volumes; explain what each port binding does.

L3Reading container logs
Week 3

Objective: Find evidence in logs.

Tail proxy and webapp logs during a login attempt; capture the request line.

L4Identifying exposed services
Week 3

Objective: Enumerate what is reachable and from where.

From student-ws, scan server-net and record the open ports; repeat from external.

L5Mapping container communications to OSI and TCP/IP
Week 4

Objective: Tie traffic to layers.

For three flows, name the layer, protocol, data unit and control at each step.

L6Capturing and analyzing simulated traffic
Week 5

Objective: Read a capture and spot the lure.

Capture on sensor while a simulated phishing click occurs; annotate the PCAP.

L7Discovering assets inside an authorized lab network
Week 6

Objective: Produce a verified inventory.

Enumerate corp-user and server-net; produce an asset table with evidence.

L8Identifying an intentionally vulnerable web application
Week 7 (revisit Week 10)

Objective: Recognize and later remediate app flaws.

Fingerprint webapp; list three candidate weaknesses with CWE IDs. Week 10: patch and re-test.

L9Applying secure configuration and container hardening
Week 8

Objective: Harden without breaking the service.

Apply non-root user, read-only filesystem, dropped capabilities and resource limits; prove the app still works.

L10Investigating authentication and access logs
Week 9

Objective: Reconstruct an auth timeline.

From idp and jump logs, reconstruct who accessed what and when.

L11Forwarding logs to a SIEM
Week 9

Objective: Get sources into one place.

Forward proxy, idp and sensor logs to siem; confirm ingestion and build one dashboard.

L12Detecting simulated adversary behavior
Week 9

Objective: Write and test a detection.

Run the provided attack script; write one detection rule and map it to ATT&CK.

L13Segmenting IT and OT container networks
Week 11

Objective: Prove OT is unreachable from IT.

Verify ot-control is reachable only via idmz; document the path and the block.

L14Testing approved firewall and access-control rules
Week 12

Objective: Validate rules by testing them.

Test each ACL rule for allow and deny; record the evidence pair.

L15Investigating a simulated IT-to-OT intrusion
Week 13

Objective: Trace a pivot into OT.

Trace the pivot from webapp → jump → historian → plc-sim; build the timeline.

L16Restoring the environment and validating remediation
Week 15

Objective: Recover and prove it.

Restore from snapshot, apply remediation, and re-run steps 4, 12 and 15 to prove closure.

Troubleshooting

`docker compose up` fails with a port conflict

Cause: Another service already owns the loopback port.

Fix: Change the left side of the mapping only (e.g. 127.0.0.1:3001:3000); never publish to 0.0.0.0.

Containers start then immediately exit

Cause: Missing volume, bad entrypoint, or read-only filesystem without tmpfs.

Fix: Run `docker compose logs <svc>`; add the tmpfs mount; re-run.

SIEM shows no events

Cause: Log forwarding blocked between segments.

Fix: Confirm log-srv and siem share sec-mgmt and that UDP 514 is permitted; restart the forwarder.

OT containers reachable from corp-user

Cause: A service is attached to two networks.

Fix: Remove the extra network from the service and re-create; re-run Docker lab 13 to verify.

Out of memory / host freezes

Cause: SIEM plus all targets on an 8 GB host.

Fix: Use the split profiles: `--profile it` or `--profile ot` instead of the full range.

Range state is dirty after an exercise

Cause: Volumes persisted between runs.

Fix: Run the documented reset: `docker compose down -v && docker compose up -d`.

Deployment options

Offline classroom: pre-pull images to a local registry or USB, then run with no internet. Cloud sandbox: deploy in an isolated VPC/subnet with no public exposure. Windows: use WSL2 backend. macOS: Docker Desktop; allocate 12 GB+. Linux: Docker Engine + Compose plugin. Snapshot a clean state before each exercise and restore from it afterward.