From a2972feb076615d944d5fa18ec2b093143b2c849 Mon Sep 17 00:00:00 2001 From: Manu Sporny Date: Sat, 27 Oct 2018 09:41:59 -0400 Subject: [PATCH 1/6] Fix all VC JSON-LD Context URLs. See #206. --- index.html | 61 ++++++++++++++++++++++++++++++++++++++---------------- 1 file changed, 43 insertions(+), 18 deletions(-) diff --git a/index.html b/index.html index 86b0d6640..0160f3ca8 100644 --- a/index.html +++ b/index.html @@ -55,7 +55,6 @@ company: "Spec-Ops", companyURL: "https://spec-ops.io/", w3cid: "44770" } ], - // authors, add as many as you like. // This is optional, uncomment if you have authors as well as editors. // only "name" is required. Same format as editors. @@ -66,7 +65,6 @@ { name: "Dave Longley", url: "http://digitalbazaar.com/", company: "Digital Bazaar", companyURL: "http://digitalbazaar.com/"} ], - // name of the WG wg: "Verifiable Claims Working Group", @@ -740,7 +738,10 @@

Types

 {
-  "@context": "https://w3id.org/credentials/v1",
+  "@context": [
+    "https://w3.org/2018/credentials/v1",
+    "https://example.com/examples/v1"
+  ],
   "id": "http://dmv.example.gov/credentials/3732",
   "type": ["VerifiableCredential", "ProofOfAgeCredential"],
   "claim": {
@@ -882,7 +883,10 @@ 

Issuer

 {
-  "@context": "https://w3id.org/credentials/v1",
+  "@context": [
+    "https://w3.org/2018/credentials/v1",
+    "https://example.com/examples/v1"
+  ],
   "id": "http://dmv.example.gov/credentials/3732",
   "type": ["VerifiableCredential", "ProofOfAgeCredential"],
   "issuer": "https://dmv.example.gov/issuers/14",
@@ -915,7 +919,10 @@ 

Proofs (e.g., Signatures)

 {
-  "@context": "https://w3id.org/credentials/v1",
+  "@context": [
+    "https://w3.org/2018/credentials/v1",
+    "https://example.com/examples/v1"
+  ],
   "id": "http://example.gov/credentials/3732",
   "type": ["VerifiableCredential", "ProofOfAgeCredential"],
   "issuer": "https://dmv.example.gov",
@@ -963,7 +970,10 @@ 

Expiration

 {
-  "@context": "https://w3id.org/credentials/v1",
+  "@context": [
+    "https://w3.org/2018/credentials/v1",
+    "https://example.com/examples/v1"
+  ],
   "id": "http://dmv.example.gov/credentials/3732",
   "type": ["VerifiableCredential", "ProofOfAgeCredential"],
   "issuer": "https://dmv.example.gov/issuers/14",
@@ -1018,7 +1028,10 @@ 

Status

 {
-  "@context": "https://w3id.org/credentials/v1",
+  "@context": [
+    "https://w3.org/2018/credentials/v1",
+    "https://example.com/examples/v1"
+  ],
   "id": "http://dmv.example.gov/credentials/3732",
   "type": ["VerifiableCredential", "ProofOfAgeCredential"],
   "issuer": "https://dmv.example.gov/issuers/14",
@@ -1059,7 +1072,10 @@ 

Presentations

 {
-  "@context": "https://w3id.org/credentials/v1",
+  "@context": [
+    "https://w3.org/2018/credentials/v1",
+    "https://example.com/examples/v1"
+  ],
   "id": "urn:uuid:3978344f-8596-4c3a-a978-8fcaba3903c5",
   "type": ["VerifiablePresentation"],
   "verifiableCredential": [{ ... }],
@@ -1165,7 +1181,10 @@ 

Extensibility

 {
-  "@context": "https://w3id.org/credentials/v1",
+  "@context": [
+    "https://w3.org/2018/credentials/v1",
+    "https://example.com/examples/v1"
+  ],
   "id": "http://example.com/credentials/4643",
   "type": ["VerifiableCredential"],
   "issuer": "https://example.com/issuers/14",
@@ -1215,7 +1234,7 @@ 

Extensibility

title="A verifiable credential with a custom extension"> { "@context": [ - "https://w3id.org/credentials/v1", + "https://w3.org/2018/credentials/v1", "https://example.com/contexts/mycontext.jsonld" ], "id": "http://example.com/credentials/4643", @@ -1351,7 +1370,7 @@

Refreshing

 {
   "@context": [
-    "https://w3id.org/credentials/v1",
+    "https://w3.org/2018/credentials/v1",
     "https://example.org/motorlicense/v1"
   ],
   "id": "http://dmv.example.gov/credentials/3732",
@@ -1424,7 +1443,7 @@ 

Terms of Use

 {
   "@context": [
-    "https://w3id.org/credentials/v1",
+    "https://w3.org/2018/credentials/v1",
     "https://example.org/motorlicense/v1"
   ],
   "id": "http://dmv.example.gov/credentials/3732",
@@ -1458,7 +1477,7 @@ 

Terms of Use

 {
   "@context": [
-    "https://w3id.org/credentials/v1",
+    "https://w3.org/2018/credentials/v1",
     "https://example.org/motorlicense/v1"
   ],
   "id": "did:example:ebfeb1f712ebc6f1c276e12ec21",
@@ -1548,7 +1567,7 @@ 

Evidence

 {
   "@context": [
-    "https://w3id.org/credentials/v1",
+    "https://w3.org/2018/credentials/v1",
     "https://example.org/motorlicense/v1"
   ],
   "id": "http://dmv.example.gov/credentials/3732",
@@ -1642,7 +1661,7 @@ 

Credential Uniquely Identifies Subject

 {
-  "@context": ["https://w3id.org/credentials/v1", "https://schema.org/"]
+  "@context": ["https://w3.org/2018/credentials/v1", "https://schema.org/"]
   "id": "http://dmv.example.gov/credentials/332",
   "type": ["VerifiableCredential", "IdentityCredential"],
   "issuer": "https://dmv.example.gov/issuers/4",
@@ -2004,7 +2023,10 @@ 

Disputes

 {
-  "@context": "https://w3id.org/credentials/v1",
+  "@context": [
+    "https://w3.org/2018/credentials/v1",
+    "https://example.com/examples/v1"
+  ],
   "id": "http://example.com/credentials/245",
   "type": ["VerifiableCredential", "DisputeCredential"],
   "claim": {
@@ -2226,7 +2248,7 @@ 

JSON-LD

processing a verifiable credential or verifiable presentation, and a @context property is not present at the top-level of the JSON-LD document, then a @context property with a value of -https://w3id.org/credentials/v1 MUST be assumed. +https://w3.org/2018/credentials/v1 MUST be assumed.

@@ -2706,7 +2728,10 @@

Bearer Credentials

 {
-  "@context": "https://w3id.org/credentials/v1",
+  "@context": [
+    "https://w3.org/2018/credentials/v1",
+    "https://example.com/examples/v1"
+  ],
   "id": "http://dmv.example.gov/credentials/temporary/28934792387492384",
   "type": ["VerifiableCredential", "ProofOfAgeCredential"],
   "issuer": "https://dmv.example.gov/issuers/14",

From b4d88ff4b4543fffc2c65b091ad2161e44885d13 Mon Sep 17 00:00:00 2001
From: Manu Sporny 
Date: Sat, 27 Oct 2018 10:29:41 -0400
Subject: [PATCH 2/6] Add note about static VC JSON-LD Context and vocab. See
 #206.

---
 index.html | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/index.html b/index.html
index 0160f3ca8..e5de4a021 100644
--- a/index.html
+++ b/index.html
@@ -2248,7 +2248,12 @@ 

JSON-LD

processing a verifiable credential or verifiable presentation, and a @context property is not present at the top-level of the JSON-LD document, then a @context property with a value of -https://w3.org/2018/credentials/v1 MUST be assumed. +https://w3.org/2018/credentials/v1 MUST be assumed. The +JSON-LD Context available at https://w3.org/2018/credentials/v1 +is a static document that is never updated and may thus be downloaded and +cached client side. The associated vocabulary document for the +Verifiable Credentials Data Model can be found at the following URL: +https://w3.org/2018/credentials.

From a635f00551b7034ad5ba6a7c7be541c360ca0ae3 Mon Sep 17 00:00:00 2001 From: Manu Sporny Date: Thu, 1 Nov 2018 15:56:19 -0400 Subject: [PATCH 3/6] Add section on Contexts. See #206. --- index.html | 48 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) diff --git a/index.html b/index.html index e5de4a021..b7a5ba12c 100644 --- a/index.html +++ b/index.html @@ -651,6 +651,54 @@

Basic Concepts

toward the end of the document.

+
+

Contexts

+ +

+When two software systems need to exchange data, they must use terminology +that both systems understand. A useful analogy is to think about how two +people communicate; both people must use the same language and the words +that each of them use must mean the same thing to the other party. This +specification uses the @context property to express the context +of the conversation. +

+ +
+
@context
+
+The value of this property MUST be one or more URIs where first URI is the +value https://w3.org/2018/credentials/v1. +If more than one URI is provided, the URIs MUST be interpreted as an +ordered set. It is RECOMMENDED that dereferencing the URI results in a +document containing machine-readable information about the context. +
+
+ +
+{
+  "@context": [
+    "https://w3.org/2018/credentials/v1",
+    ...
+  ],
+  "id": "http://dmv.example.gov/credentials/3732",
+  "type": ["VerifiableCredential", "ProofOfAgeCredential"],
+  "claim": {
+    "id": "did:example:ebfeb1f712ebc6f1c276e12ec21",
+    "ageOver": 21
+  },
+  "proof": { ... }
+}
+        
+ +

+The data available at https://w3.org/2018/credentials/v1 +is a static document that is never updated and may thus be downloaded and +cached client side. The associated vocabulary document for the +Verifiable Credentials Data Model can be found at the following URL: +https://w3.org/2018/credentials. +

+
+

Identifiers

From 27269e0b24c1fccf8abe4bc61e09a2f3d8fcd00c Mon Sep 17 00:00:00 2001 From: Manu Sporny Date: Sat, 27 Oct 2018 13:00:20 -0400 Subject: [PATCH 4/6] Refer to Extensibility section from Contexts section. --- index.html | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/index.html b/index.html index b7a5ba12c..146a36554 100644 --- a/index.html +++ b/index.html @@ -692,10 +692,11 @@

Contexts

The data available at https://w3.org/2018/credentials/v1 -is a static document that is never updated and may thus be downloaded and -cached client side. The associated vocabulary document for the +is a static document that is never updated and MAY be downloaded and +cached. The associated human-readable vocabulary document for the Verifiable Credentials Data Model can be found at the following URL: -https://w3.org/2018/credentials. +https://w3.org/2018/credentials. +This concept is expanded upon in Section .

From 23991146b767e831fd9cf6c830b56d24e7b8c3dc Mon Sep 17 00:00:00 2001 From: Manu Sporny Date: Sat, 27 Oct 2018 13:17:22 -0400 Subject: [PATCH 5/6] Add note about example context. See #245. --- index.html | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/index.html b/index.html index 146a36554..6f325e8fe 100644 --- a/index.html +++ b/index.html @@ -678,7 +678,7 @@

Contexts

{ "@context": [ "https://w3.org/2018/credentials/v1", - ... + "https://example.com/examples/v1" ], "id": "http://dmv.example.gov/credentials/3732", "type": ["VerifiableCredential", "ProofOfAgeCredential"], @@ -690,6 +690,21 @@

Contexts

}
+

+The example above uses the base context +(https://w3.org/2018/credentials/v1) to establish that the +conversation is about a Verififiable Credential. It then adds an additional +context (https://example.com/examples/v1) to establish that the +conversation will also be about examples. +

+ +

+This document uses the Example Context +(https://example.com/examples/v1) for the purposes of +demonstrating examples. The Example Context MUST NOT be used for any other +purpose such as in pilot or production systems. +

+

The data available at https://w3.org/2018/credentials/v1 is a static document that is never updated and MAY be downloaded and From 7d66396342c987f549212277897d6b106865dee8 Mon Sep 17 00:00:00 2001 From: Manu Sporny Date: Thu, 1 Nov 2018 16:13:09 -0400 Subject: [PATCH 6/6] Fix namespace documents as requested by @gkellogg. --- index.html | 6 +++--- vocab/context.jsonld | 4 ++-- vocab/credentials.html | 12 ++++++------ vocab/credentials.jsonld | 8 ++++---- vocab/credentials.ttl | 4 ++-- vocab/template.html | 6 +++--- vocab/vocab.csv | 6 +++--- 7 files changed, 23 insertions(+), 23 deletions(-) diff --git a/index.html b/index.html index 6f325e8fe..db8263d77 100644 --- a/index.html +++ b/index.html @@ -744,7 +744,7 @@

Identifiers

 {
-  "@context": "https://w3id.org/credentials/v1",
+  "@context": "https://w3.org/2018/credentials/v1",
   "id": "http://dmv.example.gov/credentials/3732",
   "type": ["VerifiableCredential", "ProofOfAgeCredential"],
   "claim": {
@@ -1381,7 +1381,7 @@ 

Semantic Interoperability

"@context": { "referenceNumber": "https://example.com/vocab#referenceNumber", "claim": { - "@id": "https://w3id.org/credentials#claim", + "@id": "https://w3.org/2018/credentials#claim", "@context": { "favoriteFood": "https://example.com/vocab#favoriteFood" } @@ -2266,7 +2266,7 @@

JSON Web Token

"aud": "www.example.com", "sub": "did:example:ebfeb1f712ebc6f1c276e12ec21", "verifiableCredential": { - "@context": "https://w3id.org/security/v1", + "@context": "https://w3.org/2018/security/v1", "id": "http://example.gov/credentials/3732", "type": ["VerifiableCredential", "ProofOfAgeCredential"], "issuer": "https://dmv.example.gov", diff --git a/vocab/context.jsonld b/vocab/context.jsonld index 3fe82f7c6..856ea4b4b 100644 --- a/vocab/context.jsonld +++ b/vocab/context.jsonld @@ -3,11 +3,11 @@ { "@version": 1.1 }, - "https://w3id.org/security/v1", + "https://w3.org/2018/security/v1", { "id": "@id", "type": "@type", - "cred": "https://w3id.org/credentials#", + "cred": "https://w3.org/2018/credentials#", "dc": "http://purl.org/dc/terms/", "schema": "http://schema.org/", "xsd": "http://www.w3.org/2001/XMLSchema#", diff --git a/vocab/credentials.html b/vocab/credentials.html index 8e01d7611..f01d93a44 100755 --- a/vocab/credentials.html +++ b/vocab/credentials.html @@ -10,7 +10,7 @@ specStatus: "base", shortName: "vc-vocab", publishDate: "2018-07-25", - thisVersion: "http://w3id.org/credentials", + thisVersion: "http://w3.org/2018/credentials", doJsonLd: true, //edDraftURI: "https://w3c.github.io/vc-vocab/", // lcEnd: "3000-01-01", @@ -72,7 +72,7 @@ .bold {font-weight: bold;} - +

This document describes the Verifiable Claims Vocabulary @@ -89,7 +89,7 @@

Published:
Imports:
http://purl.org/dc/terms/
-
https://w3id.org/security
+
https://w3.org/2018/security
Version Info:
See Also:
@@ -107,11 +107,11 @@

Introduction

This specification makes use of the following namespaces:

cred:
-
https://w3id.org/credentials#
+
https://w3.org/2018/credentials#
dc:
http://purl.org/dc/terms/
sec:
-
https://w3id.org/security#
+
https://w3.org/2018/security#
xsd:
http://www.w3.org/2001/XMLSchema#
@@ -291,7 +291,7 @@

Term Definitions

cred
- https://w3id.org/credentials# + https://w3.org/2018/credentials#
credentialStatus
diff --git a/vocab/credentials.jsonld b/vocab/credentials.jsonld index e5ea79e0b..6c4f6326b 100755 --- a/vocab/credentials.jsonld +++ b/vocab/credentials.jsonld @@ -3,11 +3,11 @@ { "@version": 1.1 }, - "https://w3id.org/security/v1", + "https://w3.org/2018/security/v1", { "id": "@id", "type": "@type", - "cred": "https://w3id.org/credentials#", + "cred": "https://w3.org/2018/credentials#", "dc": "http://purl.org/dc/terms/", "schema": "http://schema.org/", "xsd": "http://www.w3.org/2001/XMLSchema#", @@ -140,7 +140,7 @@ "@type": "@id" } }, - "@id": "https://w3id.org/credentials#", + "@id": "https://w3.org/2018/credentials#", "@type": "owl:Ontology", "dc:title": { "en": "Verifiable Claims Vocabulary" @@ -151,7 +151,7 @@ "dc:date": "2018-07-25", "owl:imports": [ "http://purl.org/dc/terms/", - "https://w3id.org/security" + "https://w3.org/2018/security" ], "rdfs:seeAlso": [ "https://www.w3.org/TR/verifiable-claims-data-model/" diff --git a/vocab/credentials.ttl b/vocab/credentials.ttl index 606819069..db5818d04 100755 --- a/vocab/credentials.ttl +++ b/vocab/credentials.ttl @@ -2,7 +2,7 @@ @prefix owl: . @prefix rdf: . @prefix rdfs: . -@prefix cred: . +@prefix cred: . @prefix schema: . @prefix xsd: . @@ -11,7 +11,7 @@ cred: a owl:Ontology; dc:title "Verifiable Claims Vocabulary"@en; dc:description """This document describes the RDFS vocabulary description used for Verifiable Claims [[verifiable-claims-data-model]] along with the default JSON-LD Context."""@en; dc:date "2018-07-25"^^xsd:date; - dc:imports , ; + dc:imports , ; rdfs:seeAlso ; # Class definitions diff --git a/vocab/template.html b/vocab/template.html index 03a3098ad..4902d7e90 100755 --- a/vocab/template.html +++ b/vocab/template.html @@ -10,7 +10,7 @@ specStatus: "base", shortName: "vc-vocab", publishDate: "<%=ont["dc:date"]%>", - thisVersion: "http://w3id.org/credentials", + thisVersion: "http://w3.org/2018/credentials", doJsonLd: true, //edDraftURI: "https://w3c.github.io/vc-vocab/", // lcEnd: "3000-01-01", @@ -112,11 +112,11 @@

Introduction

This specification makes use of the following namespaces:

cred:
-
https://w3id.org/credentials#
+
https://w3.org/2018/credentials#
dc:
http://purl.org/dc/terms/
sec:
-
https://w3id.org/security#
+
https://w3.org/2018/security#
xsd:
http://www.w3.org/2001/XMLSchema#
diff --git a/vocab/vocab.csv b/vocab/vocab.csv index 8298f90d0..ffd77109a 100644 --- a/vocab/vocab.csv +++ b/vocab/vocab.csv @@ -1,11 +1,11 @@ id,type,label,subClassOf,domain,range,@type,@container,comment -,@context,,https://w3id.org/security/v1,,,,, -cred,prefix,,https://w3id.org/credentials#,,,,, +,@context,,https://w3.org/2018/security/v1,,,,, +cred,prefix,,https://w3.org/2018/credentials#,,,,, dc,prefix,,http://purl.org/dc/terms/,,,,, schema,prefix,,http://schema.org/,,,,, xsd,prefix,,http://www.w3.org/2001/XMLSchema#,,,,, ,owl:imports,,http://purl.org/dc/terms/,,,,, -,owl:imports,,https://w3id.org/security,,,,, +,owl:imports,,https://w3.org/2018/security,,,,, ,rdfs:seeAlso,,https://www.w3.org/TR/verifiable-claims-data-model/,,,,, claim,rdf:Property,claim,,VerifiableCredential,,@id,@graph,A statement made about a `subject`. issuer,rdf:Property,issuer,,VerifiableCredential,,@id,,The value of this property MUST be a URI. It is RECOMMENDED that dereferencing the URI results in a document containing machine-readable information about the issuer that may be used to verify the information expressed in the `credential`.