Skip to content

ui-server: apply repository rules to verified immutable input and expose trustworthy review targets #3615

Open

Description

@schlessera

Out of scope

No mutable-content exemption before separate qualification, origin-wide GitHub grant or automatic trust of external PR/submodule content.

Context

Part of #3598.

inputTaintSource (packages/ui-server/src/activity/ingestion-taint.ts:95) treats workspace reads uniformly; the raw proxy cannot prove repository ownership. Implement the reviewed repository-transport qualification outcome, reusing existing private reference grants rather than equating a credential with authority.

Read the reviewed implementation design and requested gpt-6-astra review/disposition. The proposed repository plan/ADR are not yet on main 35217d283b849b5ef81700d5d4c2ec7486405d12; use the linked complete public design and review until #3599 records them. Source pointers below were verified at that main SHA, independently of the dirty working checkout. ROADMAP.md “What binds future work”, the provider-history decision, G6 and the protected policy-writer boundary apply.

Scope

  • Match configured owner/exact-repo source rules only against qualified acquisition identities and immutable managed-source reads.
  • Apply input/output trust independently, honor explicit untrusted marks first, and keep mutable/unproven worktree reads restricted.
  • Enable verified repo choices and row-capability state in Settings/history without widening recipient/write/private-access authority.

Acceptance criteria

  • Trusted immutable source reads avoid a new unresolved trigger while a foreign, mutable or changed-content path does not.
  • Explicit untrusted file marks, nested repos, copied/altered remotes and mount/symlink/hardlink escapes cannot inherit trust.
  • Stable repo/current-owner identity handles transfer/rename/name reuse per the qualified rule; missing metadata/provenance is unavailable rather than safe.
  • Removing a repo rule affects future reads and retains historical trusted-at-admission rule/hash evidence; unrelated B/C remain unresolved.
  • Private grant revocation, outbound recipient permissions, byte/deny limits and Git write approvals remain independent.

Verification

Qualified real-Git acquisition and immutable-read fixtures, fake identity metadata at the lowest request layer, authority/redirect/escape mutations and Settings/history browser integration.

Every behavioral implementation needs meaningful failing-first/mutation receipts and the relevant real runtime/browser proof. Run contribution preflight before opening a PR; missing/cancelled selected hosted proof is not green. No tests may require an API key or external network.

Contract impact

Implement the reviewed optional schema/API/history additions and the relevant effective-taint behavior. Update integration contracts and API reports in the same implementing commit with CONTRACT metadata and a minor changeset. The G6 default/coverage and effective-state semantic break follows the recorded breaking-before-1.0 ruling and breaking label; preserve mixed-version fallback.

Blocked by #3613
Blocked by #3601
Blocked by #3607
Blocked by #3611

Triage 2026-11-05 at main 35217d283b849b5ef81700d5d4c2ec7486405d12: verified source anchors and the published plan/review, retained all still-open output dependencies and existing native parent, and classified this requested but unscheduled work as priority: p2 without inventing a release milestone. The brief is complete with no independent needs gap; agent-ready may coexist with blocked, and this issue remains unpickable until its named outputs exist.

Owner-policy consumer guard

Before repository source trust is enabled, every consumer must require policyError === null as well as state === "available", qualified bindings and the existing provenance/explicit-untrusted conditions. Missing or unrecognized error state remains restrictive. Retained last-valid bindings with policyError: "policy_unavailable" are historical qualification evidence and must not alone grant source trust. Cover invalid, unreadable and symlink policy, fresh valid recovery and a mutation removing the consumer gate. Tracked in #4403 (final review of #4273).

2026-11-21 correction: added the policyError consumer gate required by the deferred final-review finding; the producer's deliberate last-valid Settings behavior is preserved.

Activity

  1. added
    type: feat
    area: ui-sdk
    area: ui-server
    area: backends
    on Nov 5, 2026
  2. added
    blocked
    contract
    security
    agent-ready
    priority: p2
    on Nov 5, 2026
  3. schlessera commented on Nov 21, 2026

    @schlessera
    OwnerAuthor

    Unblocked: #3613, #3601, #3607, #3611 are closed, so scripts/sync-project.ts is removing the blocked label.

  4. removed
    blocked
    on Nov 21, 2026
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

    agent-readyarea: backendsarea: ui-sdkarea: ui-servercontractpriority: p2securitytype: feat

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions