Skip to content

Platform administrators can read every registered repository - #993

Open
zlareb1 wants to merge 9 commits into
mainfrom
fix/platform-admin-repository-read
Open

zlareb1 wants to merge 9 commits into
mainfrom
fix/platform-admin-repository-read

Conversation

@zlareb1

@zlareb1 zlareb1 commented Nov 19, 2026 •

Copy link
Copy Markdown
Member

Related: #1087
Related: #1041
Related: #1072
Related: #1077

Changelog category (leave one):

  • Bug Fix (user-visible misbehavior in a release)

Changelog entry

Platform administrators can inspect repositories through the dashboard with an unrestricted platform token. Repository writes and delegated reads continue to require their existing grants.

Why

Repository metadata reads require a namespace viewer grant even when the caller holds unrestricted platform administration rights. The repository read authorization path recognizes that token only for the viewer role.

Scope and risk

The exception applies to repository inspection by an undelegated, unrestricted platform administrator. Member writes explicitly opt out. Restricted, delegated and impersonated tokens retain namespace checks, and assistant delegated reads retain their scope ceiling. Regression cases exercise authorization directly and through HTTP transport. The person-query prerequisite scopes observations to the authorization decision task. The replicated erasure lease fixture is already present on main; its unit controls are now on main with the existing Keeper path. The default-comparison prerequisite computes the canonical mapping once. The cleanup fixture uses one private idle clock for the real owner and connection-close budgets. Deadline values, refusal controls and behavior assertions remain unchanged. No erasure fixture DDL change is included. Documentation distinguishes request-only repository metadata from readable code and populated index status.

Compatibility, rollout and rollback

No wire fields, settings, migrations or stored data change. Operator steps: none. Reverting restores the prior repository inspection requirement.

Tests

82 administrator and restricted-namespace authorization cases pass at this head. The 69 prerequisite results are retained prior-source receipts; their feature source files are preserved in the current-main composition. Scoped Ruff, Python formatting, documentation formatting and whitespace checks pass. Full hosted CI must pass on this exact head before merge. The earlier hosted Cell acceptance result does not establish a passing latency result for this composition.

AI assistance in the code (leave one; writing this description with AI is fine):

  • AI-generated: Codex wrote the change; authorization boundaries and regression assertions were inspected.

  • I can explain every line of this diff and how it interacts with the rest of Loom.

Checklist

  • Full required hosted checks pass on this head.
  • No generated wire or schema files require changes.
  • Documentation describes the administrator read exception and token limits.
  • Commits are signed off.

The prerequisite cases comprise 47 default-comparison, 10 person-query observation, 3 erasure-fixture, 9 cleanup. Fresh independent whole review and complete hosted CI are required for this head.

@zlareb1
zlareb1 force-pushed the fix/platform-admin-repository-read branch 9 times, most recently from 3a1bc56 to 03f5699 Compare November 20, 2026 21:05
@vercel

vercel Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
loom-docs Ready Ready Preview Nov 21, 2026 12:06am UTC

Request Review

@zlareb1
zlareb1 force-pushed the fix/platform-admin-repository-read branch 3 times, most recently from cab70c5 to dc642d0 Compare November 20, 2026 23:46
Admit repository viewer reads from a platform administrator using its own unscoped authority. Preserve restricted serving, classification, tenancy, delegated-token and write boundaries.

Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Keep the ordinary namespace and organization limits when member writes check read access.

Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Cover refused and unavailable provisioning before the platform repository
read exception for both standard and restricted indexes.

Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Shared client schema reads run with an independent context. Record only decision-tagged statements while retaining unbounded decision reads as failures.

Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
(cherry picked from commit 7cd6fe5)
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Keep the blocked close, deadline observers and loop timers on one private
clock. A controlled independent clock advance reproduces the elapsed-time
dependency while the original cleanup and refusal assertions stay intact.

Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
(cherry picked from commit 4b03db4)
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Exercise each default-field refusal and JSON numeric distinction before consolidating repeated default comparisons.

Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
(cherry picked from commit 73ef63b)
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
(cherry picked from commit cb594d0)
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
Keep every default-field and JSON type check while avoiding a separate encoder setup for each field.

Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
(cherry picked from commit 0bfc712)
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
(cherry picked from commit a94d2f9)
Signed-off-by: zlareb1 <lareb.zafar@clickhouse.com>
@zlareb1
zlareb1 force-pushed the fix/platform-admin-repository-read branch from dc642d0 to e417404 Compare November 21, 2026 00:04

This branch has not been deployed

No deployments
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