From b0a1bc302a1e2529f5a150bc805dc1318521d419 Mon Sep 17 00:00:00 2001 From: gabe Date: Tue, 25 Jul 2023 13:27:11 -0700 Subject: [PATCH 1/7] update term definitions --- index.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/index.html b/index.html index c82a954..19d2673 100644 --- a/index.html +++ b/index.html @@ -155,7 +155,7 @@

Data Model

JsonSchema2023

This term definition - is https://www.w3.org/ns/credentials#JsonSchema2023. + is https://www.w3.org/TR/vc-json-schema/#JsonSchema2023.

JsonSchema2023 is for the validation of W3C Verifiable Credentials, based @@ -238,7 +238,7 @@

JsonSchema2023

VerifiableCredentialSchema2023

This term definition - is https://www.w3.org/ns/credentials#VerifiableCredentialSchema2023. + is https://www.w3.org/TR/vc-json-schema/#VerifiableCredentialSchema2023.

VerifiableCredentialSchema2023 is used for the validation of W3C Verifiable Credentials, based From c3e402e8a7f7320efc54fa1f66452d952b88bdef Mon Sep 17 00:00:00 2001 From: gabe Date: Tue, 25 Jul 2023 13:51:13 -0700 Subject: [PATCH 2/7] update usage of credential schema and surrounding text --- index.html | 33 +++++++++++++++++++++++++++------ terms.html | 4 ++++ 2 files changed, 31 insertions(+), 6 deletions(-) diff --git a/index.html b/index.html index 19d2673..ae2ffd9 100644 --- a/index.html +++ b/index.html @@ -158,8 +158,12 @@

JsonSchema2023

is https://www.w3.org/TR/vc-json-schema/#JsonSchema2023.

- JsonSchema2023 is for the validation of W3C Verifiable Credentials, based - on JSON Schema. The version of [[JSON-Schema]] can be any version noted in the section + JsonSchema2023 is used for the validation of W3C Verifiable Credentials using + JSON Schema. When dereferencing the id property associated with the + JsonSchema2023 type value the result is a valid JSON + Schema document according to its specification version. +

+ The specification version of [[JSON-Schema]] can be any version noted in the section on JSON Schema Specifications.

@@ -209,6 +213,11 @@

JsonSchema2023

+

+ Upon dereferencing the value of the id https://example.com/schemas/email.json, + a process also be referred to as schema resolution, the following JSON Schema + document is returned: +

               {
                 "$id": "https://example.com/schemas/email.json",
@@ -241,9 +250,16 @@ 

VerifiableCredentialSchema2023

is https://www.w3.org/TR/vc-json-schema/#VerifiableCredentialSchema2023.

- VerifiableCredentialSchema2023 is used for the validation of W3C Verifiable Credentials, based - on representing JSON Schema in a verifiable credential. The version of [[JSON-Schema]] - can be any version noted in the section on JSON Schema Specifications. + VerifiableCredentialSchema2023 is used for the validation of W3C Verifiable Credentials using + JSON Schema, where the JSON Schema is contained with a verifiable credential. + When dereferencing the id property associated with the + VerifiableCredentialSchema2023 type value the result is a valid + verifiable credential. The resulting verifiable credential MUST NOT + have a credentialSubject property and it MUST have a jsonSchema + property containing a valid JSON Schema, as exemplified below. +

+ The specification version of [[JSON-Schema]] can be any version noted in the section + on JSON Schema Specifications.

@@ -291,6 +307,11 @@

VerifiableCredentialSchema2023

+

+ Upon dereferencing the value of the id https://example.com/credentials/3734, + a process also be referred to as schema resolution, the following verifiable credential, + representing a JSON Schema, is returned: +

               {
                 "@context": [
@@ -301,7 +322,7 @@ 

VerifiableCredentialSchema2023

"type": ["VerifiableCredential", "VerifiableCredentialSchema2023"], "issuer": "https://example.com/issuers/14", "issuanceDate": "2010-01-01T19:23:24Z", - "credentialSubject": { + "jsonSchema": { "$id": "https://example.com/schemas/email-credential-schema.json", "$schema": "https://json-schema.org/draft/2020-12/schema", "name": "EmailCredential", diff --git a/terms.html b/terms.html index 99e0950..d8d2286 100644 --- a/terms.html +++ b/terms.html @@ -157,5 +157,9 @@ or fetching, a URL are defined by the URL [=url/scheme=]. This specification does not use the term URI or IRI because those terms have been deemed to be confusing to Web developers. + +
schema resolution
+
+The process that takes as its input a URL and returns a credential schema.
\ No newline at end of file From b010e6d85ceb25181f8d2b41e5f3387ccc2c2acf Mon Sep 17 00:00:00 2001 From: gabe Date: Tue, 25 Jul 2023 13:53:34 -0700 Subject: [PATCH 3/7] Revert term defs --- index.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/index.html b/index.html index ae2ffd9..2690b2c 100644 --- a/index.html +++ b/index.html @@ -155,7 +155,7 @@

Data Model

JsonSchema2023

This term definition - is https://www.w3.org/TR/vc-json-schema/#JsonSchema2023. + is https://www.w3.org/ns/credentials/#JsonSchema2023.

JsonSchema2023 is used for the validation of W3C Verifiable Credentials using @@ -247,7 +247,7 @@

JsonSchema2023

VerifiableCredentialSchema2023

This term definition - is https://www.w3.org/TR/vc-json-schema/#VerifiableCredentialSchema2023. + is https://www.w3.org/ns/credentials#VerifiableCredentialSchema2023.

VerifiableCredentialSchema2023 is used for the validation of W3C Verifiable Credentials using From 7eaf76812eb92306419e99369e7d3793a454f924 Mon Sep 17 00:00:00 2001 From: gabe Date: Tue, 25 Jul 2023 18:25:37 -0700 Subject: [PATCH 4/7] changes from review comments --- index.html | 75 +++++++++++++++++++++++++++++++----------------------- 1 file changed, 43 insertions(+), 32 deletions(-) diff --git a/index.html b/index.html index 2690b2c..163aa39 100644 --- a/index.html +++ b/index.html @@ -148,7 +148,7 @@

Data Model

The following sections outline the data models for this document, of which there are two: JsonSchema2023 for usage of a [[JSON-Schema]] directly in a credentialSchema - property, and VerifiableCredentialSchema2023 for usage of a [[JSON-Schema]] represented as a + property, and JsonSchemaCredential2023 for usage of a [[JSON-Schema]] represented as a verifiable credential.

@@ -244,19 +244,26 @@

JsonSchema2023

-

VerifiableCredentialSchema2023

+

JsonSchemaCredential2023

This term definition - is https://www.w3.org/ns/credentials#VerifiableCredentialSchema2023. + is https://www.w3.org/ns/credentials#JsonSchemaCredential2023.

- VerifiableCredentialSchema2023 is used for the validation of W3C Verifiable Credentials using + JsonSchemaCredential2023 is used for the validation of W3C Verifiable Credentials using JSON Schema, where the JSON Schema is contained with a verifiable credential. When dereferencing the id property associated with the - VerifiableCredentialSchema2023 type value the result is a valid - verifiable credential. The resulting verifiable credential MUST NOT - have a credentialSubject property and it MUST have a jsonSchema - property containing a valid JSON Schema, as exemplified below. + JsonSchemaCredential2023 type value the result is a valid + verifiable credential. The resulting verifiable credential's + credentialSubject property MUST contain a two properties: +

  • type – the value of which MUST be JsonSchema2023
  • +
  • jsonSchema – an object which contains a valid JSON Schema
  • +

    +

    + The term definition + for using the jsonSchema property within the credentialSubject + of a verifiable credential is https://www.w3.org/ns/credentials#JsonSchema. +

    The specification version of [[JSON-Schema]] can be any version noted in the section on JSON Schema Specifications. @@ -278,14 +285,14 @@

    VerifiableCredentialSchema2023

    - +
    typeThe type property MUST be VerifiableCredentialSchema2023The type property MUST be JsonSchemaCredential2023

    An example of utilizing the VC Data Model's credentialSchema is provided below: -
    +               
                    {
                      "@context": [
                        "https://www.w3.org/ns/credentials/v2",
    @@ -301,7 +308,7 @@ 

    VerifiableCredentialSchema2023

    }, "credentialSchema": { "id": "https://example.com/credentials/3734", - "type": "VerifiableCredentialSchema2023" + "type": "JsonSchemaCredential2023" } }
    @@ -319,33 +326,37 @@

    VerifiableCredentialSchema2023

    "https://www.w3.org/ns/credentials/examples/v2" ], "id": "https://example.com/credentials/3734", - "type": ["VerifiableCredential", "VerifiableCredentialSchema2023"], + "type": ["VerifiableCredential", "JsonSchemaCredential2023"], "issuer": "https://example.com/issuers/14", "issuanceDate": "2010-01-01T19:23:24Z", - "jsonSchema": { - "$id": "https://example.com/schemas/email-credential-schema.json", - "$schema": "https://json-schema.org/draft/2020-12/schema", - "name": "EmailCredential", - "description": "EmailCredential using VerifiableCredentialSchema2023", - "type": "object", - "properties": { - "credentialSubject": { - "type": "object", - "properties": { - "emailAddress": { - "type": "string", - "format": "email" - } - }, - "required": ["emailAddress"] - } + "credentialSubject": { + "id": "https://example.com/schemas/email-credential-schema.json", + "type": "JsonSchema2023", + "jsonSchema": { + "$id": "https://example.com/schemas/email-credential-schema.json", + "$schema": "https://json-schema.org/draft/2020-12/schema", + "name": "EmailCredential", + "description": "EmailCredential using JsonSchemaCredential2023", + "type": "object", + "properties": { + "credentialSubject": { + "type": "object", + "properties": { + "emailAddress": { + "type": "string", + "format": "email" + } + }, + "required": ["emailAddress"] + } + } } } }

    - Add language about CredentialSchema2023 credentials having a credentialSchema property + Add language about JsonSchemaCredential2023 credentials having a credentialSchema property and the risks of nesting.

    @@ -465,7 +476,7 @@

    Processing

    Integrity Validation

    Credential Schemas MAY be packaged as verifiable credentials as defined - by usage of the VerifiableCredentialSchema2023 type. + by usage of the JsonSchemaCredential2023 type. The credential containing a credential schema may include a proof, either embedded according to [[VC-DATA-INTEGRITY]] or packaged as a [[VC-JWT]].

    @@ -735,7 +746,7 @@

    Multiple Schemas

    }, "credentialSchema": { "id": "multiple-credential-schema-test", - "type": "VerifiableCredentialSchema2023" + "type": "JsonSchemaCredential2023" }, "proof": { ... } } From f7f8739ff1101542344dd5e5c13e9e5a31d98bfb Mon Sep 17 00:00:00 2001 From: gabe Date: Tue, 25 Jul 2023 18:30:52 -0700 Subject: [PATCH 5/7] add type --- index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.html b/index.html index 163aa39..cd32896 100644 --- a/index.html +++ b/index.html @@ -299,7 +299,7 @@

    JsonSchemaCredential2023

    "https://www.w3.org/ns/credentials/examples/v2" ], "id": "https://example.com/credentials/3733", - "type": ["VerifiableCredential", "EmailCredential"], + "type": ["VerifiableCredential", "JsonSchemaCredential2023", "EmailCredential"], "issuer": "https://example.com/issuers/14", "issuanceDate": "2010-01-01T19:23:24Z", "credentialSubject": { From 5cba68f19af32d8b3b6455b098155b11ae8c4ee4 Mon Sep 17 00:00:00 2001 From: gabe Date: Tue, 25 Jul 2023 18:35:42 -0700 Subject: [PATCH 6/7] use ul --- index.html | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/index.html b/index.html index cd32896..4475da6 100644 --- a/index.html +++ b/index.html @@ -256,8 +256,10 @@

    JsonSchemaCredential2023

    JsonSchemaCredential2023 type value the result is a valid verifiable credential. The resulting verifiable credential's credentialSubject property MUST contain a two properties: -
  • type – the value of which MUST be JsonSchema2023
  • -
  • jsonSchema – an object which contains a valid JSON Schema
  • +
      +
    • type – the value of which MUST be JsonSchema2023
    • +
    • jsonSchema – an object which contains a valid JSON Schema
    • +

    The term definition From 21ff4f16f9f8b7d3dd76a93c6cee5aa637aeadb3 Mon Sep 17 00:00:00 2001 From: Gabe <7622243+decentralgabe@users.noreply.github.com> Date: Wed, 26 Jul 2023 10:40:16 -0500 Subject: [PATCH 7/7] Update index.html Co-authored-by: Manu Sporny --- index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.html b/index.html index 4475da6..9869105 100644 --- a/index.html +++ b/index.html @@ -301,7 +301,7 @@

    JsonSchemaCredential2023

    "https://www.w3.org/ns/credentials/examples/v2" ], "id": "https://example.com/credentials/3733", - "type": ["VerifiableCredential", "JsonSchemaCredential2023", "EmailCredential"], + "type": ["VerifiableCredential", "ExampleEmailCredential"], "issuer": "https://example.com/issuers/14", "issuanceDate": "2010-01-01T19:23:24Z", "credentialSubject": {