Skip to content

feat(queue): land only what the submitter may change - #148

Open
PiquelChips wants to merge 1 commit into
feat/permissions-revision-checksfrom
feat/permissions-landing
Open

PiquelChips wants to merge 1 commit into
feat/permissions-revision-checksfrom
feat/permissions-landing

Conversation

@PiquelChips

Copy link
Copy Markdown
Member

Landing is the one write left unchecked: anyone can land on any target, policy included, and a revision made on an old acceptance, or another target's tip, can revert or delete what the submitter may not change.

  • land and target new take a signed-in caller who may land on the target, and only admin lands on policy.
  • The queue lands for a submitter, whose path access it holds. A landing may only change, on the target, paths they write, whatever it lands, so a stale base or a detour through another target never smuggles a change in.
  • Results promoted to the revision that lands come only from what the submitter sees.

Benchmarks: the new permissions benchmark times walking a 20k-file tip for a clone and landing a one-file edit, as the owner, under a policy without path rules, and under one that withholds a directory and keeps another read-only. Permission checks cost nothing measurable: a landing takes about 16 ms with or without rules, and a 20k-file snapshot walk about 38 ms.

Note

Written by Claude Opus 5.5 in Claude Code (via T3 Code)

@coderabbitai

coderabbitai Bot commented Nov 22, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 34 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 7d8f2a7f-4c09-46c1-b543-29ae7577f6e5
Commits

Reviewing files that changed from the base of the PR and between e87ef36 and d280e8e.

Files selected for processing: 15

  • AGENTS.md
  • apps/origin-src/Cargo.toml
  • apps/origin-src/benches/annotations.rs
  • apps/origin-src/benches/permissions.rs
  • apps/origin-src/src/annotations/mod.rs
  • apps/origin-src/src/annotations/promotion.rs
  • apps/origin-src/src/annotations/retention.rs
  • apps/origin-src/src/permissions.rs
  • apps/origin-src/src/queue/mod.rs
  • apps/origin-src/src/queue/session.rs
  • apps/origin-src/src/queue/tests/evidence.rs
  • apps/origin-src/src/queue/tests/mod.rs
  • apps/origin-src/src/service.rs
  • apps/origin-src/src/workspace/annotate.rs
  • apps/origin-src/tests/http.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@PiquelChips
PiquelChips added this pull request to stack #165 November 22, 2026 14:59
@PiquelChips
PiquelChips force-pushed the feat/permissions-landing branch 2 times, most recently from f2bc9ed to 8ff03e4 Compare November 22, 2026 16:40
@PiquelChips
PiquelChips force-pushed the feat/permissions-landing branch from 8ff03e4 to aa50e07 Compare November 22, 2026 18:54
Landing was the one write left unchecked: anyone could land on any
target, `policy` included, and a revision made on an old acceptance,
or another target's tip, could revert or delete what the submitter may
not change.

`land` and `create_target` now take a signed-in caller who may land on
the target, `admin` for `policy`. The queue lands for a submitter, whose
path access it holds: the landing must only change, on the target,
paths they write, whatever it lands, so a stale base or a detour
through another target never smuggles a change in. Results promoted to
the revision that lands come only from what the submitter sees, so a
landing never copies a result they can't read.

The new `permissions` benchmark times walking a 20,000-file tip for a
clone and landing a one-file edit, as the owner, under a policy without
path rules, and under one that withholds a directory and keeps another
read-only: permission checks cost nothing measurable. A landing takes
about 16 ms with or without rules, and the walk about 38 ms.
@PiquelChips
PiquelChips force-pushed the feat/permissions-landing branch from aa50e07 to d280e8e Compare November 22, 2026 19:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant