Repository navigation
Closed as not planned
Labels
Description
Depends on: #2526, #2527 (including the per-agent call check), #2534, #2535, #2536
Removes shortcut: shared agent identity
Problem
Real loading and registration are built but switched off, so every grant still names the shared agent identity.
Design
What
Turn on the per-agent identity from #2527:
- mecak8s startup passes the loader's records to
identitybroker.New(newIdentityBrokerininternal/app/identitybroker.gopassesniltoday); - "register agent" uses the real implementation (Per-agent registration and identities, switched on #2527) instead of the shared agent identity;
- "authorize call" (Per-call grant and gateway token #2535) applies the per-agent call check: at the broker, step (6) check 3 (Per-agent registration and identities, switched on #2527); at AS-1, Mecatl's actor-token validator (Mecatl's actor-token validator #2534) (
credentials-and-lifecycle.md, step (4) check 8); - remove the shared agent identity code path (
sharedAgentPathininternal/identitybroker/credential.go,Broker.agentIDininternal/identitybroker/broker.go), together with Per-agent registration and identities, switched on #2527's per-agent option, the conformance cases that assume one sharedag_, and Per-agent registration and identities, switched on #2527's reservation of the source nameshared.
Every registration names the source and the revision the loader (#2526) reports. Exact definition versions (#2547 to #2549) and the full loader (#2551) come later and change only where the revision comes from.
The phase 1 call sites (session start, MCP call) stay where they are, with one server change:
- the server's returned-agent check (the suffix
/inst/<incarnation>inregisterIdentityAgent,internal/adapter/server/identity_broker.go) moves to the broker package'sRegistration.Matches(RegisterAgentRequest)from Per-agent registration and identities, switched on #2527, because per-agent IDs carry the definition and parent chain; - the server keeps the held-agent comparison.
How it fits
Every grant now names the specific agent that acted, such as Alice's main agent, instead of the shared agent identity.
Done when
In the fixture:
- each session's main agent has its own SPIFFE ID and
ag_identifier; - every grant carries the agent's
ag_identifier inact.sub, never a SPIFFE path (Mecatl's actor-token validator #2534), and the log names it; - the broker refuses an agent not registered to the call's broker session without calling AS-1;
- AS-1 refuses an agent whose session belongs to another user than the grant's;
- the server checks each returned agent with
Registration.Matches, and no other call site outside startup wiring changed.
Activity
feat(identitybroker): return each loaded definition with its record
refactor(identitybroker): address advisory review findings on the loader
ChrisJBurns commentedon Nov 18, 2026
Merged into #2527.