whitehat-security/engagements/runtime/WH-ENG-20260822-AUDIT-E2-03-invocation.md
tegwick 96d6781036 Prepare receipt-bound audit E2 third attempt
Assistant: codex
Assistant-Model: gpt-5.6-sol
Assistant-Session: 01a02991-be07-7bb3-8b6d-e9701b5621de
2026-08-22 23:23:48 +02:00

4 KiB
Raw Blame History

WH-ENG-20260822-AUDIT-E2-03 — attended invocation

This package is proposed for 22:00Z22:15Z; projection closes at 22:03Z. Do nothing live until the engagement and the exact WP-0025 contract are approved and audit-core has acknowledged them.

Runtime value-safe artifacts are written beneath /tmp/WH-ENG-20260822-AUDIT-E2-03/:

  • broker.json
  • projection.json
  • runner-report.json
  • cleanup.json
  • final-report.json

The platform contract is /home/worsch/railiance-platform/docs/WH-ENG-20260822-AUDIT-E2-03-custody-contract.json.

Broker gate, projection, and admission

From railiance-platform, after approval and before the window:

python3 scripts/wp0025-broker-readiness.py approve \
  --contract docs/WH-ENG-20260822-AUDIT-E2-03-custody-contract.json \
  --consumer-root /home/worsch/whitehat-security \
  --reviewer whitehat-owner \
  --receipt-out /tmp/WH-ENG-20260822-AUDIT-E2-03/broker.json

python3 scripts/custody-projection.py preflight \
  --contract docs/WH-ENG-20260822-AUDIT-E2-03-custody-contract.json

At or after 22:00Z, no later than 22:03Z:

python3 scripts/custody-projection.py project \
  --contract docs/WH-ENG-20260822-AUDIT-E2-03-custody-contract.json \
  --confirm WH-ENG-20260822-AUDIT-E2-03:attended \
  --receipt-out /tmp/WH-ENG-20260822-AUDIT-E2-03/projection.json

From whitehat-security, admit before applying the runner:

PYTHONPATH=src python3 -m whitehat_security.cli admit-plane \
  engagements/2026-08-22-audit-core-e2-03.json \
  targets/audit-core-e2.json \
  --receipt /tmp/WH-ENG-20260822-AUDIT-E2-03/projection.json \
  --contract /home/worsch/railiance-platform/docs/WH-ENG-20260822-AUDIT-E2-03-custody-contract.json \
  --broker-receipt /tmp/WH-ENG-20260822-AUDIT-E2-03/broker.json

Runner

Only after admission succeeds:

ssh -o BatchMode=yes railiance01 kubectl apply -f - \
  < engagements/runtime/whitehat-e2-audit-20260822-03.yaml
ssh -o BatchMode=yes railiance01 kubectl -n whitehat wait \
  --for=condition=Ready pod/whitehat-e2-audit-03 --timeout=60s

Stream runners/audit_core_e2.py to python3 - inside that pod with these exact arguments:

--base-url http://audit-core.audit-core.svc.cluster.local:8080
--engagement-id WH-ENG-20260822-AUDIT-E2-03
--authorization-id operator-session-2026-08-22-e2-03-approval
--target-revision sha256:c2fe39a0185b99be3fc0cb14d2de69772b8e66e20490097c9d11d90cc39719a6
--token-a-file /var/run/secrets/whitehat/token-a
--token-b-file /var/run/secrets/whitehat/token-b
--tenant-a tenant:trial:whitehat-a-20260822-03
--tenant-b tenant:trial:whitehat-b-20260822-03
--event-a whitehat-e2-event-a-20260822-03
--event-b whitehat-e2-event-b-20260822-03
--absent-event whitehat-e2-absent-20260822-03
--forged-event whitehat-e2-forged-b-20260822-03
--correlation whitehat-e2-correlation-20260822-03
--occurred-at 2026-08-22T22:00:00Z
--rate 10 --max-requests 30 --abort-p95-ms 500

The runner output is the sanitized runner-report.json. Delete the runner immediately after execution, whether it passes, finds, or aborts.

Cleanup and report finalization

From railiance-platform, before 22:15Z:

python3 scripts/custody-projection.py cleanup \
  --contract docs/WH-ENG-20260822-AUDIT-E2-03-custody-contract.json \
  --receipt /tmp/WH-ENG-20260822-AUDIT-E2-03/projection.json \
  --confirm WH-ENG-20260822-AUDIT-E2-03:cleanup \
  --receipt-out /tmp/WH-ENG-20260822-AUDIT-E2-03/cleanup.json

From whitehat-security, bind the report to the cleanup receipt and deliver it:

PYTHONPATH=src python3 -m whitehat_security.cli finalize-report \
  /tmp/WH-ENG-20260822-AUDIT-E2-03/runner-report.json \
  --contract /home/worsch/railiance-platform/docs/WH-ENG-20260822-AUDIT-E2-03-custody-contract.json \
  --receipt /tmp/WH-ENG-20260822-AUDIT-E2-03/projection.json \
  --cleanup-receipt /tmp/WH-ENG-20260822-AUDIT-E2-03/cleanup.json \
  --output /tmp/WH-ENG-20260822-AUDIT-E2-03/final-report.json

PYTHONPATH=src python3 -m whitehat_security.cli deliver \
  /tmp/WH-ENG-20260822-AUDIT-E2-03/final-report.json --outbox outbox