Skip to content

Resolve bare DID aliases for trust and cert lookups#9

Open
Eskyee wants to merge 1 commit into
Gitlawb:mainfrom
Eskyee:fix/normalize-agent-did-profile
Open

Resolve bare DID aliases for trust and cert lookups#9
Eskyee wants to merge 1 commit into
Gitlawb:mainfrom
Eskyee:fix/normalize-agent-did-profile

Conversation

@Eskyee
Copy link
Copy Markdown

@Eskyee Eskyee commented May 19, 2026

Summary

  • normalize bare agent profile/trust identifiers like z6MkpUq1... to full did:key:z6MkpUq1... before trust lookup
  • make gl cert <repo> resolve owner-less repo names against the caller DID instead of the node DID
  • let gl cert show accept the short certificate ID printed by gl cert list

Repro fixed

  • gl node trust did:key:z6MkpUq1Aw4mgNwwzhEd4f4eYvrUeizwmoT7NyiBx1e8Z9UY => contributor trust with pushes
  • gl node trust z6MkpUq1Aw4mgNwwzhEd4f4eYvrUeizwmoT7NyiBx1e8Z9UY previously showed newcomer/0 pushes
  • gl cert list agentbot-opensource previously resolved to the node owner and printed No ref certificates found
  • latest valid cert on the owner repo is 3686b1fe-afdf-428b-9fca-8745ad6f8a18 for refs/heads/main -> 3ac9fd6d8ca69337982c7bef212271d613fe8b56

Verification

  • cargo check -p gl
  • cargo run -q -p gl -- cert list agentbot-opensource
  • cargo run -q -p gl -- cert show agentbot-opensource 3686b1fe
  • cargo check -p gitlawb-node
  • cargo test -p gitlawb-node normalize_agent_did

Public profile and CLI surfaces accept bare z6Mk keys, but trust and certificate data are stored against full did:key identities. Normalize agent profile lookups and make cert commands resolve owner-less repos against the caller DID so valid pushes are not hidden behind node-owned paths.

Constraint: Public URLs and CLI examples commonly use short z6Mk identifiers

Constraint: Ref certificates are issued after push and stored under the owner repo id

Rejected: Register duplicate bare-key identities | would split trust and certificate history across aliases

Rejected: Require full certificate UUIDs in show output | list already displays short IDs as the human-facing handle

Confidence: high

Scope-risk: narrow

Directive: Keep bare key inputs as aliases for did:key, not separate identities

Tested: cargo check -p gl

Tested: cargo run -q -p gl -- cert list agentbot-opensource

Tested: cargo run -q -p gl -- cert show agentbot-opensource 3686b1fe

Tested: cargo check -p gitlawb-node

Tested: cargo test -p gitlawb-node normalize_agent_did
@Eskyee Eskyee force-pushed the fix/normalize-agent-did-profile branch from fc3f0cf to b88994d Compare May 19, 2026 13:20
@Eskyee Eskyee changed the title Normalize bare agent keys before trust lookup Resolve bare DID aliases for trust and cert lookups May 19, 2026
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