Skip to content

feat(identity): record identity/ownership verifiable claims - #2125

Draft
ramizpolic wants to merge 3 commits into
mainfrom
feat/identity-add
Draft

ramizpolic wants to merge 3 commits into
mainfrom
feat/identity-add

Conversation

@ramizpolic

Copy link
Copy Markdown
Member

Summary

Adds a verifiable identity/ownership claim system for OASF records (identity.v1), purely additive — naming.v1 is left fully intact and untouched in this PR (removed in a follow-up stacked PR).

  • proto/api: IdentityClaim/OwnershipClaim messages, IdentityService (GetIdentityStatus, Resolve), and the api/identity/v1 Go package: claim construction, detached-JWS signing/verification (ES256/ES384/EdDSA/RS256), mandatory per-trust-domain SPIFFE trust bundles (no silent fallback), and OCI referrer marshaling. Adds Record.GetIdentity/GetOwner/GetIdentityType/GetOwnerType annotation accessors and Record.GetDigest (sha256:hex form, for OCI/ai-catalog.io interop).
  • server: server/identity resolvers (dns/did/wellknown/spiffe) behind a common Resolver registry, the SSRF-safe utils/safefetch HTTP client they share, a unified claims DB table (record_cid + role), and eager claim verification wired into ingest.
  • client/cli/reconciler: SDK methods (SignAndAttachIdentityClaim/OwnershipClaim, GetIdentityStatus(ByName), Resolve), dirctl identity claim/status/resolve, identity/owner search flags, and a reconciler task that periodically re-verifies claims (catching key rotation, expiry, and revoked SPIFFE trust bundles).

Design note

This PR is deliberately additive-only so it builds and passes tests standing alone: naming.v1's NamingServiceClient, its DB API (NameVerificationDatabaseAPI), CLI, and reconciler task are untouched. A couple of naming collisions between the old and new code were resolved by keeping both (e.g. an expandNameWithProtocols helper duplicated under a different name) rather than removing anything — naming.v1's actual removal happens in the follow-up stacked PR (feat/identity-remove-legacy).

Verification

go build && go vet && go test pass across api, server, client, cli, reconciler, tests, samples/ard-over-ads.

…ntity.v1)

Introduces IdentityClaim/OwnershipClaim proto messages and IdentityService
(GetIdentityStatus, Resolve), plus the api/identity/v1 Go package: claim
construction, detached-JWS signing/verification (ES256/ES384/EdDSA/RS256,
mandatory SPIFFE trust bundles), and OCI referrer marshaling.

Adds Record.GetIdentity/GetOwner/GetIdentityType/GetOwnerType annotation
accessors and Record.GetDigest (sha256:hex form, for OCI/ai-catalog.io
interop). Registers the two new referrer types in the CEL validator
allowlist, and adds identity/owner search query types.
…tion

Adds server/identity: a Resolver registry plus dns/, did/, wellknown/, and
spiffe/ implementations that verify a claim's detached JWS against a
resolved public key (DNS TXT record, DID document, .well-known JWKS, or a
mandatory per-trust-domain SPIFFE CA bundle — no silent fallback).

Adds the SSRF-safe utils/safefetch HTTP client (https-only, blocks
private/loopback/link-local/metadata addresses, re-checked post-DNS-resolve
to close the rebinding window) used by the dns/wellknown/did resolvers.

Adds server/database/gorm's claims table (one row per record_cid + role,
composite unique index) replacing the old identity_claims/ownership_claims
split, with search filters (WithIdentities/WithOwners/*Verified) and
record-association preloading. Wires eager claim verification into the
ingest path and identity config into server startup.
…ication task

Adds client.SignAndAttachIdentityClaim/OwnershipClaim, GetIdentityStatus(ByName),
and ResolveIdentity to the Go SDK. Adds `dirctl identity claim/status/resolve`
and identity/owner search flags (--identity, --owner, --identity-verified,
--owner-verified) to `dirctl search`.

Adds reconciler/tasks/identity: periodically re-verifies identity/ownership
claim referrers (catching key rotation, expiry, and revoked SPIFFE trust
bundles that eager ingest-time verification can't observe later).

Updates the trust-model, records-validation, Go SDK, and skill-reference
docs for the new identity/ownership claim model.

This PR is purely additive: naming.v1 (NamingServiceClient, its DB API, CLI,
and reconciler task) is left fully intact and untouched. The new identity
resolve method is named ResolveIdentity (not Resolve) specifically to avoid
colliding with naming.v1's existing Client.Resolve; a couple of other
naming-clashes (a duplicated expandNameWithProtocols helper, the DatabaseAPI
interface embed) were resolved the same way, by renaming/re-adding rather
than removing anything. naming.v1's removal is a separate follow-up PR.
@github-actions

github-actions Bot commented Sep 8, 2026

Copy link
Copy Markdown
Contributor

The latest Buf updates on your PR. Results from workflow Buf CI / verify-proto (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed⏩ skipped⏩ skipped✅ passedSep 8, 2026, 5:46 PM

@kperry-godaddy

Copy link
Copy Markdown

Do we have any ETA when this will merge?

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/XL Denotes a PR that changes 2000+ lines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants