docs(tess): remediate M5 qualification findings #750

Merged
jason.woltje merged 2 commits from feat/tess-m5v-remediation into main 2026-07-13 19:59:40 +00:00
Owner

M5-V remediation

Complete in this PR:

  • Replace stale MosCoordinationService and mos-coordination.service.ts operational references with InteractionCoordinationService and its current path.
  • Add docs/SITEMAP.md linking the Tess guides, architecture/security, OpenAPI, migration, and verification docs.
  • Replace stale threat-model blocker list with closed controls and current evidence paths.
  • Add focused CLI/TUI gateway error coverage for attach (401), send (400 invalid request), and stop (403 forbidden).

Constraints honored: docs/test-only; tracking trio untouched; command authorization unchanged.

Verification

  • focused gateway-api.interaction-errors.test.ts (3 tests)
  • TURBO_FORCE=true pnpm typecheck (42 tasks green)
  • Codex code and security review: no findings

Refs #706.

## M5-V remediation Complete in this PR: - [x] Replace stale `MosCoordinationService` and `mos-coordination.service.ts` operational references with `InteractionCoordinationService` and its current path. - [x] Add `docs/SITEMAP.md` linking the Tess guides, architecture/security, OpenAPI, migration, and verification docs. - [x] Replace stale threat-model blocker list with closed controls and current evidence paths. - [x] Add focused CLI/TUI gateway error coverage for attach (401), send (400 invalid request), and stop (403 forbidden). Constraints honored: docs/test-only; tracking trio untouched; command authorization unchanged. ## Verification - focused `gateway-api.interaction-errors.test.ts` (3 tests) - `TURBO_FORCE=true pnpm typecheck` (42 tasks green) - Codex code and security review: no findings Refs #706.
jason.woltje added 1 commit 2026-07-13 19:17:09 +00:00
docs(tess): remediate M5 qualification findings
All checks were successful
ci/woodpecker/pr/ci Pipeline was successful
32d431b42b
Author
Owner

ROR-750-REQUEST-CHANGES-32d431b4

Verdict: REQUEST CHANGES for PR #750 at exact live head 32d431b42b9bcf7c56015a373b5e55445e9ab985.

Evidence checked:

  • Live PR head verified via git ls-remote origin refs/pull/750/head; fetched head matches 32d431b42b9bcf7c56015a373b5e55445e9ab985.
  • Base/merge-base is origin/main 405984af5ac19bdd51e89e4415e6b1b88a1a08ce; PR view reports no conflicts.
  • Woodpecker PR CI 1794 is SUCCESS for commit 32d431b42b9b.
  • Scope is 8 files as advertised: 7 docs + packages/mosaic/src/tui/gateway-api.interaction-errors.test.ts.
  • PR body uses Refs #706 only; no closing keyword for mission #706 observed.
  • Tracking trio untouched: no diff to docs/tess/MISSION-MANIFEST.md, docs/tess/TASKS.md, or docs/tess/VERIFICATION-MATRIX.md.
  • Command authorization is not in the PR file set / diff; runtimeActionDigest blob hash remains a9f829e7ecec721c6c585fe0da56fb5d6a6441e9 at base and head.
  • No live credentials found in the diff; no Tess/tess literal in changed non-test source.

Blockers:

  1. The new interaction denial tests do not genuinely exercise gateway denial paths. packages/mosaic/src/tui/gateway-api.interaction-errors.test.ts stubs global fetch to return synthetic 401/400/403 Response objects, then verifies client-side error string formatting. That is useful TUI mapping coverage, but it is not a real gateway/API denial-path test and does not prove attach 401, send invalid-request, or stop forbidden behavior from the gateway.
  2. The stubbed send-invalid-request expectation is not faithful to current gateway code: apps/gateway/src/agent/interaction.controller.ts throws ForbiddenException('Content and idempotency key are required'), which is HTTP 403, not 400. A synthetic 400 in the TUI test can pass while disagreeing with the actual controller.
  3. docs/tess/MOS-COORDINATION.md still contains stale renamed symbols in its contract/adaptor sections (MosHandoffRequest, MosHandoffReceipt, MosHandoff, MosCoordinationPort, InMemoryMosCoordinationPort). Those no longer match current code (InteractionCoordination* / Handoff* / InMemoryInteractionCoordinationPort).

Suggested remediation: add real route/controller-level denial coverage (Nest/Fastify or equivalent) for the advertised attach/send/stop statuses, align the send invalid-request expected status with actual code or change the controller intentionally with tests, and update the remaining stale coordination symbols in docs/tess/MOS-COORDINATION.md.

No merge/deploy performed by reviewer.

ROR-750-REQUEST-CHANGES-32d431b4 Verdict: REQUEST CHANGES for PR #750 at exact live head `32d431b42b9bcf7c56015a373b5e55445e9ab985`. Evidence checked: - Live PR head verified via `git ls-remote origin refs/pull/750/head`; fetched head matches `32d431b42b9bcf7c56015a373b5e55445e9ab985`. - Base/merge-base is `origin/main` `405984af5ac19bdd51e89e4415e6b1b88a1a08ce`; PR view reports no conflicts. - Woodpecker PR CI `1794` is SUCCESS for commit `32d431b42b9b`. - Scope is 8 files as advertised: 7 docs + `packages/mosaic/src/tui/gateway-api.interaction-errors.test.ts`. - PR body uses `Refs #706` only; no closing keyword for mission #706 observed. - Tracking trio untouched: no diff to `docs/tess/MISSION-MANIFEST.md`, `docs/tess/TASKS.md`, or `docs/tess/VERIFICATION-MATRIX.md`. - Command authorization is not in the PR file set / diff; `runtimeActionDigest` blob hash remains `a9f829e7ecec721c6c585fe0da56fb5d6a6441e9` at base and head. - No live credentials found in the diff; no `Tess`/`tess` literal in changed non-test source. Blockers: 1. The new interaction denial tests do not genuinely exercise gateway denial paths. `packages/mosaic/src/tui/gateway-api.interaction-errors.test.ts` stubs global `fetch` to return synthetic 401/400/403 `Response` objects, then verifies client-side error string formatting. That is useful TUI mapping coverage, but it is not a real gateway/API denial-path test and does not prove attach 401, send invalid-request, or stop forbidden behavior from the gateway. 2. The stubbed send-invalid-request expectation is not faithful to current gateway code: `apps/gateway/src/agent/interaction.controller.ts` throws `ForbiddenException('Content and idempotency key are required')`, which is HTTP 403, not 400. A synthetic 400 in the TUI test can pass while disagreeing with the actual controller. 3. `docs/tess/MOS-COORDINATION.md` still contains stale renamed symbols in its contract/adaptor sections (`MosHandoffRequest`, `MosHandoffReceipt`, `MosHandoff`, `MosCoordinationPort`, `InMemoryMosCoordinationPort`). Those no longer match current code (`InteractionCoordination*` / `Handoff*` / `InMemoryInteractionCoordinationPort`). Suggested remediation: add real route/controller-level denial coverage (Nest/Fastify or equivalent) for the advertised attach/send/stop statuses, align the send invalid-request expected status with actual code or change the controller intentionally with tests, and update the remaining stale coordination symbols in `docs/tess/MOS-COORDINATION.md`. No merge/deploy performed by reviewer.
jason.woltje added 1 commit 2026-07-13 19:37:05 +00:00
test(gateway): exercise interaction denial routes
All checks were successful
ci/woodpecker/pr/ci Pipeline was successful
658ad2887f
Author
Owner

ROR-750-VERIFIED-APPROVE-658ad288

VERIFIED APPROVE reviewer-of-record [W-jarvis:reviewer] head 658ad2887f98ab160ba247036f59adcc4c38e23f.

Evidence checked:

  • Live PR head verified via git ls-remote origin refs/pull/750/head; fetched head matches 658ad2887f98ab160ba247036f59adcc4c38e23f.
  • Base/merge-base remains origin/main 405984af5ac19bdd51e89e4415e6b1b88a1a08ce; CI 1795 is SUCCESS for this commit.
  • Prior blocker 1 closed: real route/controller-level denial coverage was added in apps/gateway/src/agent/hermes-runtime-reachability.e2e.test.ts. It boots Nest/Fastify with AgentModule, actual AuthGuard, and InteractionController, then uses app.inject against real HTTP routes for attach/send/stop denial behavior.
  • Prior blocker 2 closed: send invalid request now asserts the actual controller behavior: ForbiddenException('Content and idempotency key are required') → HTTP 403; stop missing approval also asserts 403; unauth attach asserts 401.
  • Prior blocker 3 closed: docs/tess/MOS-COORDINATION.md no longer contains MosCoordination, MosHandoff, or InMemoryMosCoordinationPort; naming is updated to InteractionCoordination*, Handoff*, and InMemoryInteractionCoordinationPort.
  • Hard invariant reconfirmed: apps/gateway/src/commands/command-authorization.service.ts is unchanged; head blob hash remains a9f829e7ecec721c6c585fe0da56fb5d6a6441e9; 7-field runtimeActionDigest remains intact.
  • PR body is Refs #706 non-closing; issue #706 remains open. Tracking trio remains untouched. No live creds found; no changed non-test source carries an improper Tess literal.

No merge/deploy performed by reviewer.

ROR-750-VERIFIED-APPROVE-658ad288 VERIFIED APPROVE reviewer-of-record [W-jarvis:reviewer] head `658ad2887f98ab160ba247036f59adcc4c38e23f`. Evidence checked: - Live PR head verified via `git ls-remote origin refs/pull/750/head`; fetched head matches `658ad2887f98ab160ba247036f59adcc4c38e23f`. - Base/merge-base remains `origin/main` `405984af5ac19bdd51e89e4415e6b1b88a1a08ce`; CI `1795` is SUCCESS for this commit. - Prior blocker 1 closed: real route/controller-level denial coverage was added in `apps/gateway/src/agent/hermes-runtime-reachability.e2e.test.ts`. It boots Nest/Fastify with `AgentModule`, actual `AuthGuard`, and `InteractionController`, then uses `app.inject` against real HTTP routes for attach/send/stop denial behavior. - Prior blocker 2 closed: send invalid request now asserts the actual controller behavior: `ForbiddenException('Content and idempotency key are required')` → HTTP `403`; stop missing approval also asserts `403`; unauth attach asserts `401`. - Prior blocker 3 closed: `docs/tess/MOS-COORDINATION.md` no longer contains `MosCoordination`, `MosHandoff`, or `InMemoryMosCoordinationPort`; naming is updated to `InteractionCoordination*`, `Handoff*`, and `InMemoryInteractionCoordinationPort`. - Hard invariant reconfirmed: `apps/gateway/src/commands/command-authorization.service.ts` is unchanged; head blob hash remains `a9f829e7ecec721c6c585fe0da56fb5d6a6441e9`; 7-field `runtimeActionDigest` remains intact. - PR body is `Refs #706` non-closing; issue #706 remains open. Tracking trio remains untouched. No live creds found; no changed non-test source carries an improper `Tess` literal. No merge/deploy performed by reviewer.
jason.woltje merged commit d077183554 into main 2026-07-13 19:59:40 +00:00
jason.woltje deleted branch feat/tess-m5v-remediation 2026-07-13 19:59:40 +00:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: mosaicstack/stack#750