Commit graph

2 commits

Author SHA1 Message Date
trvon
39c5bc4efe
range: host-safety preflight, verified teardown, per-range scheduler identity
Host safety: range_up refuses to start below 10 GiB MemAvailable or 20 GiB free
disk, range_status prints the headroom, and the README documents both floors
and the 8 GiB pause a monitor should enforce. The 2026-11-17 global OOM was
caused by fifteen concurrent compilers plus the range, not the range alone, but
starting blind is what made it easy.

Teardown: sensor ids come from the vms/ contents rather than SB_RANGE_SENSORS,
so a lowered count or missing pid file cannot leave a VM behind; vm_pid accepts
a PID only when its command line still names that sensor's QEMU and disk, so a
recycled PID is never counted as live or signalled; a /proc sweep covers QEMUs
whose pid file was lost; --destroy refuses while any of them survives and
deletes only the sensor-N disks and seeds this range created.

Scheduler: range_up writes a per-range pid file and up/down/status act only on
a PID whose command line runs this repo's range_attack.py with SB_RANGE_DIR
resolving here, replacing the host-wide pkill that could kill another range.

Status: agents are reported live/stale/unknown per sensor group instead of a
raw registration total (six registrations for three VMs after restarts), and
the scheduler line now separates verified incidents from those without
execution proof, reporting "rule-pushed" rather than implying observed labels.
2026-11-17 13:45:22 -07:00
trvon
af5bfa78e5
validation: multi-sensor range for real promotion-gate evidence
An isolated local lab that extends the single-VM de-risk (deploy/validation/vm,
2026-11-08) to a multi-sensor fleet run over days, to produce the delayed-label
history the Stage 4 fleet gate needs. All local/offline: Caldera on loopback
(rootless Docker, capped), sensor VMs reach it only via the qemu slirp gateway,
no traffic leaves the host; payloads are inert markers (a copy of /bin/sleep
with a marker string), never real malware.

- range_up.sh: boot/resume Caldera + N Arch VMs running the real daemon
  (eBPF + fanotify), benign workload and a Caldera agent as systemd units;
  idempotent and travel-safe (VM disks + scheduler state persist under
  $SB_RANGE_DIR, the scheduler paces by its own uptime, so suspend/reboot just
  pauses it and range_up.sh resumes).
- range_workload.sh: varied benign activity so the detector learns a real
  baseline the emulated incidents must stand out from.
- range_attack.py: one distinct Caldera incident per 30-90 min per sensor
  (fresh ability + operation so each lands in its own replay window); incidents
  are unknown to the rules at exec time, then a later rule-file update + rules
  reload lets the retro-hunt label the earlier windows -- the delayed extra
  positives the gate measures, produced the production way, not injected.
- range_status.sh / range_down.sh (pause or --destroy), README, cloud-init.

Nothing here writes to the repo; the $SB_RANGE_DIR runtime tree is disposable.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-11-15 09:43:22 -07:00