Skip to content

did:nostr: align DID-document @context to cid/v1 per updated CG spec#581

Open
jjohare wants to merge 1 commit into
JavaScriptSolidServer:gh-pagesfrom
jjohare:did-nostr-spec-cidv1
Open

did:nostr: align DID-document @context to cid/v1 per updated CG spec#581
jjohare wants to merge 1 commit into
JavaScriptSolidServer:gh-pagesfrom
jjohare:did-nostr-spec-cidv1

Conversation

@jjohare

@jjohare jjohare commented Jul 3, 2026

Copy link
Copy Markdown
Contributor

Summary

Aligns buildDidDocument's @context[0] to the Controlled Identifiers v1.0 context (https://www.w3.org/ns/cid/v1), matching the current did:nostr Community Group spec example shapes (https://nostrcg.github.io/did-nostr/). The generic w3id.org/did context does not define the Multikey term used by the document; cid/v1 is what the CG spec references.

Change

  • src/idp/well-known-did-nostr.js: buildDidDocument @context['https://www.w3.org/ns/cid/v1', 'https://w3id.org/nostr/context'].

Absolute auth/assertion references are kept as-is (JSS's existing deliberate choice). This is a one-line context reconciliation to keep JSS byte-aligned with the emerging standard.

Context

Part of a cross-ecosystem did:nostr convergence (JSS + a Rust port + agent tooling) tracking the CG spec. Filed as a first-class-collaborator alignment; happy to adjust to maintainer preference.

🤖 Generated by Claude Code

The updated did:nostr CG spec (https://nostrcg.github.io/did-nostr/) canonical
example uses @context[0] = https://www.w3.org/ns/cid/v1 (Controlled Identifiers
v1.0 — the context that defines the Multikey term) rather than the generic
https://w3id.org/did. Update buildDidDocument + its conformance test assertion.
Multikey/publicKeyMultibase (fe70102) unchanged. Auth refs kept absolute
(did:nostr:<hex>#key1): the spec example uses relative #key1 but DID Core permits
both, and this indexer deliberately absolutizes auth refs.

Co-Authored-By: jjohare <[email protected]>
@jjohare
jjohare requested a review from melvincarvalho as a code owner July 3, 2026 22:05
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