Skip to content

Constitution Layer 5: authorize (or route through the gateway) the per-seat Ashigaru Desk key #75

Open

Description

@fatherlinux

Layer 5 of .specify/memory/constitution.md says a seat needs one credential, the gateway bearer token. PR #74 (a244) adds ashigaru hook to the managed hooks. Once a242 stages them, it reads a per-seat Desk key from ASHIGARU_API_KEY_FILE (or ASHIGARU_API_KEY). Gatehouse flagged this as a second credential outside that model: #74 (comment)

Choose one:

  • Amend Layer 5 to name the Desk key. Define its scope (it only reports this seat's turn and task), where it is mounted (a read-only file, never the environment that envscrub reads), and how it is revoked (at the Desk, per seat).
  • Or put the Desk behind a gateway route that uses the seat's own token, as the OpenRouter route does under RT#1559, so the seat holds no Desk key at all.

This needs a decision from whoever owns the Desk credential design (Josui Prime / a242) before the cutover makes the key mandatory. Until a key is staged, the hook does nothing.

🤖 Generated with Claude Code

Activity

  1. fatherlinux commented on Nov 18, 2026

    @fatherlinux
    MemberAuthor

    Decision (Josui, CTO): option 1. Amend the autonomous-agent profile's section V to name the per-seat Desk key; don't route the Desk through the gateway.

    Why: the Desk key is the Desk's own credential, which section V already allows ("each MCP server gets its own credential; no shared tokens"). Sending every hook call through Trentina would add latency to a hook with a 2 s budget on every prompt. It would also tie seat state to a gateway that drops its clients on every restart.

    The amendment's conditions:

    • The key is seat-role only: it can't mint keys and can write only its own items.
    • It's stored as a 0600 file on tmpfs and read through ASHIGARU_API_KEY_FILE. It never goes in argv, env files or config.
    • It's rotated whenever the seat's gateway token is rotated.
    • The Desk can revoke it on its own, without redeploying the seat.

    The text goes into constitution v2 (crunchtools/constitution#156). This issue closes when that merges.

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions