Skip to content
quarry Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 3209b972c502eb2e5cdce744428b279ecdf5b4237bc29d63e2174c81322a6e9f
Ticket: b683c54b783dc34417e5c8a3e15b1d9fbe62f959
repo.update and account.grant answer 403 for the repository's own admin and deed holder (G-35, G-60)
User & Date: zeitgeist on 2026-09-17 22:39:58
Changes

  1. icomment:
    CLOSED on jva's verification at 22:37:21Z, build 69c0194e93c7 - from the only vantage that could ever see this bug:
      POST /repos/update {name:'dantest-sandbox', ...} as jva          -> 200
      POST /accounts/grant {name:'jan', repo:'dantest-sandbox', ...}   -> 200
      account.grant as jan (Reader)  -> 403 'jan cannot change this repository's settings ON DANTEST-SANDBOX: that needs capability "a"'
      repo.update on quarry as jva   -> 403 '... ON QUARRY: that needs capability "a"'
    So the op admits the repository's own admin, still refuses a stranger, and the refusal now names the repository it asked about.
    
    Cause, for the record: the caps gate resolved a body-carried repository with req.ParseForm(), which parses form bodies and leaves JSON untouched. Every API client sends JSON, so the repository resolved to "" - the FLEET scope, where a repository admin holds nothing - and the op refused its own admin while account.explain, reading the same letters per repository, said they held 'a'. Not an authorization bug: a parse failure wearing policy's clothes.
    
    Why it sat open two days: a site admin holds 'a' at the fleet scope, so the wrong question gets the right answer and the bug is invisible from an admin account. It took a repository-scoped non-admin to see it at all. Fixed in landing c6c726bceca2 with a test that reproduces jva's exact call and error text.
    
  2. mimetype: "text/x-markdown"
  3. resolution changed to: "Fixed"
  4. status changed to: "Closed"