3 Commits
Author SHA1 Message Date
John SmithandClaude beef779d51 fix(gateway): strict CORS allowlist, forward caller identity to engine proxies
- CORS: replace wildcard origins + credentials with an env-driven
  allowlist (CORS_ALLOW_ORIGINS), mirroring the engine's strict_cors.
- identity: engine proxies (spawn/cast-spell/move/turn-next/damage/
  reactions-arm, plus attack and death-save) now verify the caller's
  token and mint a forwarded-identity HMAC token carrying the real
  user_id and role, so the engine's RBAC authorizes the actual actor.
  Previously every proxied action spoke as 'orchestrator-service' with
  no role and was rejected ENTITY_NOT_OWNED on player-owned entities —
  deployed characters could not be driven end-to-end. Omitting the
  token keeps legacy service-mediated behavior.
- tests: proxy identity forwarding, 401 on invalid tokens, contract
  route updated to act as GM.

Co-Authored-By: Claude <[email protected]>
2026-08-24 00:42:52 -04:00
John SmithandClaude 18239bf7b5 feat(wave15): zero-trust hardening, real WFC, write-through Postgres, RBAC, Yjs default
Phase 1-5 remediation + four-gap closure:
- Authoritative engine: ids-only combat payloads (deny_unknown_fields),
  server-side stat blocks, ActionBudget consumption, cover->AC, LoS gating,
  difficult-terrain Dijkstra, HMAC auth middleware + strict CORS
- Honest metrics: live-engine synthetic playtest with trust-boundary probes,
  MCR = valid/(valid+rejected), benchmark script boots its own engine
- Mechanics: condition lifecycle timers, spell slot economy w/ damage caps,
  topological ModifierSource graph, reaction stack (Shield/Counterspell/OA),
  X-card full ledger replay restoration
- Persistence: sqlx write-through tailer to event_sourcing_log,
  snapshot persist/hydrate bridge, recursive CTE inventory functions
- vtt-wfc: dead solver activated (reseed-retry contradictions, flood-fill
  single-region guarantee, deterministic dressing); fixed template removed
- RBAC: role claims in gateway tokens, identity propagation, entity
  ownership, spectator/owner enforcement, fog layer ownership at WS
- Client: PixiJS v8 board layer, physics dice with server-predetermined
  faces, Silero VAD, HRTF PannerNode chain, Y.Doc CRDT default transport
  with HMAC-authenticated ysync relay and LWW fallback

Co-Authored-By: Claude <[email protected]>
2026-08-23 22:41:53 -04:00
John Smith d2ccf6dfd3 feat(full-stack): add interactive React UI and Docker Compose stack (Tracks A & B) 2026-08-22 18:13:17 -04:00