Skip to content
quarry Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 688c60953f48a0d83f42fb02674e99deab8f5c1f8122f6ea2fd26c87b67f866a
Ticket: 0ba3b3f730a59a9145f8fb15a296b1932f5df4d0
Account management is missing from the API (Principle 5)
User & Date: dmestas on 2026-08-17 23:42:03
Changes

  1. comment changed to:
    Account management exists only as a CLI. There is no `account.*` op, so it is absent from the ops registry, absent from `docs/api.md`, and unreachable by any client.
    
        quarry account add|passwd|grant|revoke|delete|list
    
    0001 Principle 5 says a feature is not done until its full capability is exposed through a documented API, "sufficient that a complete quarry client could be built from the API spec alone, with zero screen-scraping". Account management is a feature of the forge and it fails that test.
    
    ## Consequences today
    
    - **An operator must have shell access on the server to create a login.** There is no way to add a user remotely, from a script, or from any UI.
    - **The web has no admin surface for accounts.** `/fleet` reports ingest health and mirrors; it cannot list who has access to what, which is the question an operator actually asks.
    - **Nothing else can be built on it.** Invite flows, self-registration, an identity provider, or importing users from a fossil repository all need account creation to be callable.
    
    ## What is needed
    
    `account.list`, `account.add`, `account.passwd`, `account.grant`, `account.revoke`, `account.delete`, all `ops.Admin`, with the CLI reimplemented on top so there is one implementation rather than two that can disagree.
    
    Two details worth stating up front:
    
    1. **The verifier never leaves the database.** `Account` already omits the hash; the ops must not reintroduce it. Listing accounts returns names, admin flag, created — never `pwhash`.
    2. **Password on the wire.** `account.add` and `account.passwd` take a plaintext password, so they are the two ops that must never be logged. The op layer logs errors with context today; these need a carve-out, and it should be enforced rather than remembered.
    
    ## Related
    
    Private repositories (separate ticket) need per-repository grants to be manageable to be usable at all — granting `read` on a private repo is the whole workflow, and it currently requires a shell.
    
    
  2. status changed to: "Open"
  3. title changed to:
    Account management is missing from the API (Principle 5)