diff --git a/.gitignore b/.gitignore index 0dc7b4b0..f21888c0 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ -/.vscode \ No newline at end of file +/.vscode +.idea diff --git a/diagrams/figure-a.1-did-and-did-document-graph.png b/diagrams/figure-a.1-did-and-did-document-graph.png new file mode 100644 index 00000000..6ba58e78 Binary files /dev/null and b/diagrams/figure-a.1-did-and-did-document-graph.png differ diff --git a/diagrams/figure-a.2-also-known-as-graph.png b/diagrams/figure-a.2-also-known-as-graph.png new file mode 100644 index 00000000..deaf5986 Binary files /dev/null and b/diagrams/figure-a.2-also-known-as-graph.png differ diff --git a/diagrams/figure-b.1-controller-and-subject-equivalence.png b/diagrams/figure-b.1-controller-and-subject-equivalence.png new file mode 100644 index 00000000..356ae784 Binary files /dev/null and b/diagrams/figure-b.1-controller-and-subject-equivalence.png differ diff --git a/diagrams/figure-c.1-independent-did-controllers.png b/diagrams/figure-c.1-independent-did-controllers.png new file mode 100644 index 00000000..1591ff51 Binary files /dev/null and b/diagrams/figure-c.1-independent-did-controllers.png differ diff --git a/diagrams/figure-c.2-group-did-controllers.png b/diagrams/figure-c.2-group-did-controllers.png new file mode 100644 index 00000000..a88e217d Binary files /dev/null and b/diagrams/figure-c.2-group-did-controllers.png differ diff --git a/index.html b/index.html index 92ba1681..bb15931b 100644 --- a/index.html +++ b/index.html @@ -760,6 +760,14 @@

DID Syntax

idchar = ALPHA / DIGIT / "." / "-" / "_" +

+This ABNF does not currently permit an empty method-specific-id +string. Some DID methods have expressed an interest in providing +resolution of an DID with an empty method-specific-id string, +for example to enable discovery of a DID document describing a +verifiable data registry by resolving the DID method name alone. +

+

For requirements on DID methods relating to the DID syntax, see Section . @@ -1378,10 +1386,8 @@

However, the fully resolved DID document always contains a valid id property. The value of id in the resolved DID document MUST match the DID that was -resolved, or be populated with the equivalent canonical DID -specified by the DID method, which SHOULD be used by the resolving -party going forward. -

+resolved. +

A DID document can contain objects which have their own unique @@ -1441,6 +1447,7 @@

Also Known As

+
@@ -2628,7 +2635,9 @@

consumption rules in the [[INFRA]] specification.

-Note that the value of the @context object member will be ignored, if present. That is, this field will not have additional processing applied to its value and will be added verbatim to the abstract data model. +Note that the @context object member, if present, will not have +additional processing applied to its value, which will be added verbatim to the +abstract data model.

@@ -3061,7 +3070,6 @@

CBOR to JSON

-
@@ -3586,11 +3594,11 @@

This specification defines the following common properties.

-
-
-created -
-
+
+

+ created +

+

DID document metadata SHOULD include a created property to indicate the timestamp of the Create operation. This property MAY not be supported by a given DID method. @@ -3599,18 +3607,132 @@

Definition Language (XSD) 1.1 Part 2: Datatypes [[XMLSCHEMA11-2]]. This datetime value MUST be normalized to UTC 00:00, as indicated by the trailing "Z". -

-
-updated -
-
+

+

+ +
+

+ updated +

+

DID document metadata SHOULD include an updated property to indicate the timestamp of the last Update operation. This property MAY not be supported by a given DID method. The value of the property MUST follow the same formatting rules as the created property. - - +

+
+ +
+

equivalentId

+

+ A DID Method can define different forms of a DID that are + logically equivalent. An example is when a DID takes one form prior + to registration in a verifiable data registry and another form after + such registration. In this case, the DID Method specification + may need to express one or more DIDs that are logically equivalent to + the resolved DID as a property of the DID document. This is the + purpose of the equivalentId property. +

+ +
+
equivalentId
+
+ The value of equivalentId MUST be a + list where each item in the list + is a string that conforms to the rules in Section . +
+
+ The relationship is a statement that each equivalentId + value is logically equivalent to the id property + value and thus identifies the same DID subject. +
+
+ Each equivalentId DID value MUST be produced by, and a form of, + the same DID Method as the id property value. + (e.g. did:example:abc == did:example:ABC) +
+
+ A conforming DID Method specification MUST guarantee that each + equivalentId value is logically equivalent to the + id property value. +
+
+ A resolving party MUST retain the values from the id and + equivalentId properties to ensure any subsequent + interactions with any of the values they contain are correctly handled + as logically equivalent (e.g. retain all variants in a database so an + interaction with any one maps to the same underlying account). The testability of + resolving parties is currently under debate and normative statements related to resolving parties + may be downgraded in the future from a MUST to a SHOULD/MAY or similar language. +
+
+ +
+

+ equivalentId is a much stronger form of equivalence than + alsoKnownAs because the equivalence MUST be guaranteed by + the governing DID method. equivalentId represents a full + graph merge because the same DID document describes both the + equivalentId DID and the id property DID. +

+
+ +
+ +
+

canonicalId

+

+ The canonicalId property is identical to the + equivalentId property except: a) it accepts only a single + value rather than a list, and b) that DID is defined to be the canonical ID + for the DID subject within the scope of the containing DID document. +

+ +
+
canonicalId
+
+ The value of canonicalId MUST be a string that conforms to the rules in Section . +
+
+ The relationship is a statement that the canonicalId + value is logically equivalent to the id property value and + that the canonicalId value is defined by the + DID Method to be the canonical ID for the DID subject in the scope + of the containing DID document. +
+
+ A canonicalId value MUST be produced by, and a form of, + the same DID Method as the id property value. + (e.g. did:example:abc == did:example:ABC) +
+
+ A conforming DID Method specification MUST guarantee that the + canonicalId value is logically equivalent to the + id property value. +
+
+ A resolving party MUST use the canonicalId value + as its primary ID value for the DID subject and treat all other equivalent + values as secondary aliases. (e.g. update corresponding primary references in + their systems to reflect the new canonical ID directive). The testability of + resolving parties is currently under debate and normative statements related to resolving parties + may be downgraded in the future from a MUST to a SHOULD/MAY or similar language. +
+
+ +
+

+ canonicalId is the same statement of equivalence as + equivalentId except it is constrained to a single value that + is defined to be canonical for the DID subject in the scope of the DID + document. Like equivalentId, canonicalId + represents a full graph merge because the same DID document describes both + the canonicalId DID and the id property DID. +

+
+ +
@@ -4288,6 +4410,42 @@

+
+

+ Equivalence Properties +

+

+ The three equivalence properties defined in Core Properties + —alsoKnownAs, equivalentId, and + canonicalId—are subject to special security + considerations related to attacks against DIDs that are asserted to be + equivalent. Each of the equivalence property sections describes relevant + mitigation instructions. In general, they are: +

+

+ The equivalentId and canonicalId properties + that constrain equivalence assertions to variants of a single DID produced by + the same DID method (e.g. did:foo:123did:foo:hash(123)) + can be trusted to the extent the resolving party trusts the DID method (and a + conforming producer) itself. +

+

+ The alsoKnownAs property that permits an equivalence assertion + to URIs that are not governed by the same DID method (or may not be DIDs at + all) cannot be trusted without performing verification steps outside of the governing + DID method. See Section 5.1.1 for the recommendation to verify inverse relationships. +

+

+ As with any other sensitive properties in the DID Document (e.g. public key references), + parties relying on any equivalence statement in a DID Document should guard against the + values of these properties being substituted by an attacker after the proper verification + has been performed. Any write access to a DID document stored in memory or disk after + verification has been performed is an attack vector that will circumvent verification + unless the DID document is re-verified. +

+ +
+
@@ -4789,6 +4947,319 @@

Current Issues

+
+

What Does a DID Identify?

+

+ The DID Core specification states that a DID identifies the + DID subject—and that a DID subject can be anything that can be + identified with a URI. However some applications of DIDs, particularly + those involving the Semantic Web, may need a more precise definition of how + DID identification works. That is the purpose of this Appendix. +

+

What types of resources can a DID identify?

+

+ Since a DID is a specific type of URI, the answer to this question is + provided by section 1.1 of the URI specification [[!RFC3986]]: +

+
+ This specification does not limit the scope of what might be a resource; + rather, the term "resource" is used in a general sense for whatever might be + identified by a URI. Familiar examples include an electronic document, an + image, a source of information with a consistent purpose (e.g., "today's + weather report for Los Angeles"), a service (e.g., an HTTP-to-SMS gateway), + and a collection of other resources. A resource is not necessarily + accessible via the Internet; e.g., human beings, corporations, and bound + books in a library can also be resources. Likewise, abstract concepts can + be resources, such as the operators and operands of a mathematical equation, + the types of a relationship (e.g., "parent" or "employee"), or numeric + values (e.g., zero, one, and infinity). +
+

+ In other words, it does not matter whether a resource is “on” or “off” the + Internet—if it can be identified, it can be assigned a URI, and therefore it + can be assigned a DID. +

+

How do you know what a DID identifies?

+

+ For any DID, the DID controller determines the DID subject. + Unfortunately it is all but impossible to determine the DID subject + from looking at the DID itself. The reason is that, in order to satisfy + several core properties of a DID as an identifier—especially + decentralization and cryptographic verifiability—DIDs are generally + only meaningful to machines, not humans. To illustrate, compare the following + two URIs: +

+

+ https://www.w3.org/2019/did-wg/WorkMode/getting-started +

+

+ did:example:8uQhQMGzWxR8vw5P3UWH1j +

+

+ The first is the URL of the Getting Started page of the W3C DID Working + Group. This is a human-meaningful identifier (at least to someone who + understands the English language). In this sense, the reader can be said to + “know” what the URL identifies without having to dereference it (provided + the reader trusts the publisher’s label). +

+

+ The second URI—the example DID—is meaningless to humans no matter what + language you speak. What it identifies is anyone’s guess in the absence of + further information describing the DID subject. So further information + about the DID subject is only discoverable by resolving the DID + to the DID document, obtaining a verifiable credential about the + DID, or via some other description of the DID. +

+

Does the DID identify the DID document?

+

+ No. To be very precise, the DID identifies the DID subject and + resolves to the DID document (by following the protocol + specified by the DID method). The DID document is not a + separate resource from the DID subject and does not have a URI + separate from the DID. Rather the DID document is an artifact + of DID resolution controlled by the DID controller for the + purpose of describing the DID subject. +

+

+ This distinction is illustrated by the graph model shown in figure 2. +

+
+ 
+Diagram showing a graph model for how DID controllers assign DIDs to identify
+DID subjects and resolve to DID documents that describe the DID subjects.
+          +
+ A DID is an identifier assigned by a DID controllers + to identifies a DID subject and resolve to a + DID document that describes the DID subject. The + DID document is an artifact of DID resolution and + not a separate resource distinct from the DID subject. +
+
+ +

How does the DID document describe the DID subject?

+

+ Each property in a DID document is a statement by the + DID controller that describes: +

+ +

+ There is only one required property in a DID document—the id + property—so that is the only statement guaranteed to be in a DID document. + That statement is illustrated by the solid red arrow in figure 2 asserting + that the DID identifies the DID subject. +

+ +

How can you discover more information about the DID subject?

+

+ This is the purpose of the alsoKnownAs property. The + DID controller can use it to provide a list of other URIs (including + DIDs) that identify the same DID subject. Resolving or + dereferencing these URIs may yield other descriptions or representations of + the DID subject as illustrated in figure 3. +

+
+ 
+            Diagram showing a graph model that adds to figure 2 by showing an
+            alsoKnownAs property with an arc to another node representing a
+            different resource that dereferences to another description of the
+            DID subject.
+          +
+ A DID document can use the alsoKnownAs property to assert + another URI (including another DID) that identifies the + same DID subject +
+
+

+ This mechanism is how DID identification can fulfill a longstanding + recommendation from the W3C in Cool + URIs for the Semantic Web: +

+
+ Given only a URI, machines and people should be able to retrieve a + description about the resource identified by the URI from the Web. Such + a look-up mechanism is important to establish shared understanding of + what a URI identifies. Machines should get RDF data and humans should + get a readable representation, such as HTML. +
+

+ Note that, although it is not required that a DID document use an + RDF-based representation such as JSON-LD, that format would meet the letter + of this W3C recommendation. +

+ +

Can the DID document serve as a representation of the DID subject?

+

+ If the DID subject is an information resource that can be retrieved + from the Internet, then yes, the DID document can serve as a + representation of the DID subject. For example, a data schema that + needs a persistent, cryptographically verifiable identifier could be + assigned a DID, and its DID document could be used as a + standard way to retrieve a representation of that schema. +

+ +

Can existing web resources also be assigned DIDs?

+

+ Yes, if the controller of a web page or any other web resource wants to + assign it a persistent, cryptographically verifiable identifier, the + controller can give it a DID. For example, the author of a blog + hosted by a blog hosting company (under that hosting company’s own URL) + could create a DID for the blog. In the DID document, the + author can include an alsoKnownAs property pointing to the current URL of + the blog: +

+ + “alsoKnownAs”: [“https://myblog.blogging-host.example.com/home”] + +

+ If the author subsequently moves the blog to a different hosting company + (or to the author’s own domain), the author can update the DID document + to point to the new URL for the blog: +

+ + “alsoKnownAs”: [“https://myblog.example.com/”] + +

+ The DID effectively adds a layer of indirection for the blog URL. + This layer of indirection is under the control of the author instead of + under external administrative authority such as a blog hosting company. This + is how DIDs can effectively function as + URNs (Uniform Resource + Names)—persistent identifiers for information resources whose network + location may change over time. +

+
+ +
+

+ DID Controllers and DID Subjects +

+

+ To avoid confusion about the relationship between DID controllers and + DID subjects, the DID Working Group has found it helpful to classify + DID subjects into two disjoint sets based on their relationship to + the DID controller. +

+

Set 1: The DID subject is the DID controller

+

+ The first case, shown in figure 4, is the common scenario where the + DID subject is also the DID controller. This is the case when + an individual or organization creates a DID to self-identify. +

+
+ 
+            Diagram showing the same graph model as figure 2 except with an
+            equivalence arc from the DID subject to the DID controller.
+          +
+ The DID subject is the same entity as the DID controller +
+
+

+ From a graph model perspective, even though the nodes identified as the + DID controller and DID subject in figure 4 are distinct, + there is a logical arc connecting them to express a semantic equivalence + relationship (in RDF/OWL, this is expressed using the owl:sameAs predicate). +

+

Set 2: The DID subject is not the DID controller

+

+ The second case, shown in figure 2 in the previous appendix, is when the + DID subject is a separate entity from the DID controller. This + is the case when, for example, a parent creates a DID for a child; a + corporation creates a DID for a subsidiary; or a manufacturer creates + a DID for a product, an IoT device, or a digital file. +

+

+ From a graph model perspective, the only difference between figure 2 and + figure 4 is that in the latter there is an equivalence arc relationship + between the DID subject and DID controller nodes. +

+
+ +
+

+Multiple DID Controllers +

+

+ A DID document may have more than one DID controller. In this + situation there are two basic options available for how control is shared. +

+

Option #1: Independent Control

+

+ In the first option, shown in figure 5, each of the DID controllers + may act on its own, i.e., each one has full power to update the + DID document independently. From a graph model perspective, in this + configuration: +

+ +
+ 
+            Diagram showing three DID controllers each with an independent
+            control relationship with the DID document
+          +
+ Multiple independent DID controllers that can each act + independently +
+
+ +

Option #2: Group Control

+

+ In the second option, the DID controllers must act together in some + fashion, such as when using a cryptographic algorithm that requires multiple + digital signatures (“multi-sig”) or a threshold number of digital + signatures (“m-of-n”). From a functional standpoint, this option is similar + to a single DID controller because, although each of the + DID controllers in the DID controller group has its own graph + node, the actual control collapses into a single logical graph node + representing the DID controller group as shown in figure 6: +

+
+ 
+            Diagram showing how three DID controllers act together as a single
+            DID controller group to control a DID document
+          +
+ Multiple DID controllers who must act together as a + DID controller group +
+
+

+ This configuration will often apply when the DID subject is an + organization, corporation, government agency, community, or any other group + that is not controlled by a single individual. +

+
+

IANA Considerations @@ -5059,5 +5530,6 @@

application/did+dag+cbor

+