Skip to content

[Frontier] [BROW16-01A] Prove a modern browser mediation contract #408

Open

Description

@chayapats

Parent

#397 — #397; complete S16 target #392.

Model tier

Frontier: this slice requires judgment about protected authority, lifecycle/recovery or a new cross-client/service contract; exact new APIs and migrations are not yet settled.

Context to read

AGENTS.md; CONTEXT.md; docs/agents/workflow.md; docs/specs/S16-rakazo-experience.md; docs/specs/S15-conversational-autonomy.md; ADR 0064 and ADRs 0074–0077; docs/design/S16-rakazo-experience.md; docs/design/S16-mobbin-research.md. Reuse the completed design research; do not repeat broad Mobbin discovery.

Starting implementation/contract surfaces: src/s15/browser/{types,engine,gateway,egress,provisioned}.ts; src/s15/vm/network.ts; docs/contracts/s15-protected-browser-v1.md; docs/contracts/s15-runtime-feasibility-v1.md. Read their current definitions and relevant tests before selecting changes. Paths with braces denote existing module families, not settled new signatures.

Deliverable

Select and demonstrate a useful protected modern-browser architecture with request-level effect/disclosure enforcement and a concrete public Schway/Jit contract. This feasibility child does not close #397.

Baseline and readiness

Audited stack head 17b814220371cd1e2126be2ec9bd9753537f69e6; main remains the pre-S16 baseline. #398/#399/#403/#404 are open drafts, not merged/live acceptance. Existing S15 services are reusable baseline, and #400/#401 supply draft text/binary custody. No new behavior is claimed here. Branches/PRs and issue ownership were inspected on 2026-11-05; this new ticket has no implementation claim. Recheck at dispatch. Preserve the primary-owned jit/402-s16-file-memory branch.

Scoped investigation is eligible after ownership check on this baseline; its output must be reviewed before dependent runtime implementation.

Implementation steps

  1. Recheck ownership, branches/PRs, prerequisites and exact source baseline. Compare existing implementation, pinned Rakazo reuse and a simpler alternative; record the chosen tradeoff and versioned contract before coding.
  2. Compare existing protected Chromium general mode against a simpler mediated browser service; inspect actual supported public engine contracts.
  3. Prototype a real scripted dynamic site with navigation, form editing, JS requests and login handoff outside guest root.
  4. Trace fetch/XHR/forms/WebSocket/service-worker/download/redirect and raw protocol/guest egress bypasses; classify supported operations by trusted handlers.
  5. Record reviewed request/response/input/credential/settlement contracts, limitations and replacement proof plan in an ADR; publish upstream blocker only for reproduced missing public capability.
  6. Integrate the authored experience using real service facts, English/Thai dictionary keys in their designated files, accessible loading/error/empty/reconnect states and current capabilities. For non-UI evidence work, verify those states instead of inventing new UI. Record migrations, compatibility and exact build evidence.

Acceptance criteria

  • Dynamic task completes with real browser interaction; static GET alone fails.
  • Held exact effect dispatches once and changed payload/recipient invalidates approval.
  • Guest root/raw CDP cannot retrieve sessions or bypass mediator.
  • Crash after dispatch remains unknown until evidence reconciliation.
  • Deliverable works end to end through its actual owning service/client; source presence, transport success and model prose alone are insufficient.
  • No S14 default, S15 opt-in, installed policy, historical private scope or owner-host configuration changes without its separate explicit transition.
  • New contracts, unresolved limits and exact revision/evidence are recorded; applicable upstream licenses, immutable provenance and modified-file notices ship.

Tests and evidence

  1. Dynamic task completes with real browser interaction; static GET alone fails. Use scripted models, protocol fixtures, fake clocks and barriers for deterministic cases; assert actual resulting state/bytes/effects.
  2. Held exact effect dispatches once and changed payload/recipient invalidates approval. Use scripted models, protocol fixtures, fake clocks and barriers for deterministic cases; assert actual resulting state/bytes/effects.
  3. Guest root/raw CDP cannot retrieve sessions or bypass mediator. Use scripted models, protocol fixtures, fake clocks and barriers for deterministic cases; assert actual resulting state/bytes/effects.
  4. Crash after dispatch remains unknown until evidence reconciliation. Use scripted models, protocol fixtures, fake clocks and barriers for deterministic cases; assert actual resulting state/bytes/effects.
  5. Run relevant existing module/composed regressions plus the new scenario suite; for rendered behavior, exercise the real bundle in English/Thai, keyboard and mobile widths. Record exact test paths/commands in the PR after implementation selects them.
  6. Keep real host/account/device checks opt-in and evidence-labelled; no absent credential blocks independent deterministic work. Public evidence contains hashes/outcomes only; installation-specific details belong in ignored .local records.

Requirements

S16-AC06, S16-AC07; FR-07, FR-10, FR-17, FR-18, FR-35, FR-36, FR-37, FR-38, FR-40, FR-41, NFR-07, NFR-10, NFR-11, NFR-14. Retain S15 authority decisions and FR/NFR identifiers.

Blocked by

None for this bounded feasibility investigation against the pinned planning baseline. It delivers a reviewed contract, not general-browser product acceptance.

Contracts used/delivered

Use current owning POLICY, DATA15, TEAM, MEM, WORK, CHAT and S16 client/file contracts where relevant, plus Schway's supported public host surface. Specific inputs and proposed delivery: src/s15/browser/{types,engine,gateway,egress,provisioned}.ts; src/s15/vm/network.ts; docs/contracts/s15-protected-browser-v1.md; docs/contracts/s15-runtime-feasibility-v1.md. The Deliverable and ordered steps define the missing contract outcome; freeze version, schemas, migration/recovery and conformance fixtures in the implementation ADR/PR. Proposed operations are not already supported APIs. A demonstrated missing engine seam requires a bounded public-only reproduction and a linked Schway contract ticket, never an internal import or duplicate runtime.

Out of scope

Other tickets' outcomes, hosted multi-user SaaS, marketplace operation, upstream branding, silent billing, replacing Schway, general historical data conversion, and unapproved live deployment. Live credentials, real-device acceptance and owner-host cutover are separately owned by LIVE16-01/CUT16-01; deterministic implementation remains in scope.

Do not

Do not use source/model/tool output as authority; expose credentials, sensitive-site sessions or protected state to working execution (trusted-site sessions are the S16-D09 exception); remove guards before proof; auto-retry unknown effects; weaken or bypass the S16-D07 human-required list or let anything but the in-chat owner decision approve it; treat current stack limitations as scope cuts; add model attribution; use implement-parallel; alter #402 ownership; self-merge or deploy. No placeholder controls or fabricated success.

Definition of done

Run bun install --frozen-lockfile, bun run typecheck, bun test --timeout 30000 for affected deterministic suites, and git diff --check; record exact selected suite commands and results. Add real-browser tests for rendered paths and package checks for shipped artifacts. Pure feasibility documentation runs link/coverage checks and git diff --check; a prototype must run its conformance cases. PR body includes Closes #408 and Refs #392, contract versions, tested head and honest pending evidence. No self-merge; parent #392 remains open until full accepted outcomes.

Owner revision 2026-11-06

Grok-style autonomy (S16-D06–D11, ADR 0084) and Telegram removal (ADR 0085) apply. Only the S16-D07 human-required list waits for the owner, approved by a one-press in-chat card; GitHub push/PR/review replies/merge after required checks are the product default; trusted sites may keep sessions in the working VM browser while sensitive sites stay in the protected browser. Jit has no messaging channel; notifications use Web Push (#441). Policy/approval changes belong to #442.

Scope narrowed: the remaining isolation and dispatch-crash proofs apply to the protected browser used for sensitive sites. Public and trusted-site work runs in the working VM browser; record that path and its accepted residual instead of mediating it.

Activity

  1. added
    needs-triageMaintainer needs to evaluate this issue.
    ready-for-agentImplementation-ready; start only when required blockers and ownership checks pass.
    and removed
    needs-triageMaintainer needs to evaluate this issue.
    on Nov 5, 2026
  2. chayapats commented on Nov 5, 2026

    @chayapats
    OwnerAuthor

    Bounded prototype and ADR/contract are available in draft #436 at 1ad223c7a4d1931681c22dbcfed688bbdfc28c72, based on #434. The selected candidate retains protected general Chromium and the current public Schway tool boundary after comparing pinned Rakazo computer/CDP placement and a separate remote service. No upstream source/dependency was imported.

    The probe reproduced a real readiness gap: explicit navigation ended before initial fetch/XHR callbacks reached the active scope. General navigation now shares native-click navigation's bounded networkidle barrier; every request still needs its own real current policy claim. No effect attribution, standing policy or background session is added.

    Actual macOS arm64 Chrome conformance: four new cases passed (56 assertions) and four existing controlled regressions passed (134 assertions). Static mode cannot obtain the JS-created task; general mode completes protected login/TOTP, fetch/XHR hydration, editing, exact approval and one actual service effect. Changed recipient requires a new action; actual intercepted JS mutation and submit-time substitution are denied. An actual dispatched but unverified response remains unknown with no replay. Deterministic browser/effect/disclosure/composition: 144 pass, 5 opt-in skips; service-package: 154 pass; frozen install/typecheck/doc-links/diff checks pass.

    This does not close #408/#397: physical guest-root/session/CDP/network/mount isolation and dispatch-crash/read-back remain unproven and contract review is pending. The PR names exact builds and the loopback DNS/dial fixture seam. #409 still needs a reviewed intent/request binding for representative asynchronous mutations and actual product integration; #410 owns graphical takeover. No owner-host activation, runtime-default/config/schema change, merge, deployment or full parity claim.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    ready-for-agentImplementation-ready; start only when required blockers and ownership checks pass.

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions