w3c / vc-jose-cose

Verifiable Credentials Working Group — VC JSON Web Tokens specification
https://w3c.github.io/vc-jose-cose/
Other
30 stars 9 forks source link

Controller document examples #154

Open OR13 opened 1 year ago

OR13 commented 1 year ago

capturing comments from https://github.com/w3c/vc-jose-cose/pull/144/files

So we can merge it.

OR13 commented 1 year ago

I think we should add the following example:

{
  "@context": [
    "https://www.w3.org/ns/did/v1",
    "https://www.w3.org/ns/credentials/v2"
  ],
  "id": "https://vendor.example/issuers/42",
  "verificationMethod": [
    {
      "id": "https://vendor.example/issuers/42/keys/urn:ietf:params:oauth:jwk-thumbprint:sha-256:NzbLsXh8uDCcd-6MNwXF4W_7noWXFZAfHkxZsRGC9Xs",
      "type": "JsonWebKey2020",
      "controller": "https://vendor.example/issuers/42",
      "publicKeyJwk": {
        "kty": "OKP",
        "crv": "Ed25519",
        "x": "43dp_AtlK65wWjpqgQZDkjm8WLLM5HjPBNxRfPRjuhc"
      }
    }
  ],
  "assertionMethod": [
    "https://vendor.example/issuers/42/keys/urn:ietf:params:oauth:jwk-thumbprint:sha-256:NzbLsXh8uDCcd-6MNwXF4W_7noWXFZAfHkxZsRGC9Xs"
  ],
  "authentication": [
    "https://vendor.example/issuers/42/keys/urn:ietf:params:oauth:jwk-thumbprint:sha-256:NzbLsXh8uDCcd-6MNwXF4W_7noWXFZAfHkxZsRGC9Xs"
  ]
}
selfissued commented 1 year ago

Adding more examples could help make the spec more approachable to developers.

decentralgabe commented 2 months ago

I will update examples after https://github.com/w3c/vc-jose-cose/issues/140