Copyright © 2019 W3C® (MIT, ERCIM, Keio, Beihang). W3C liability, trademark and permissive document license rules apply.
This document provides implementation guidance for Verifiable Credentials.
This section describes the status of this document at the time of its publication. Other documents may supersede this document. A list of current W3C publications and the latest revision of this technical report can be found in the W3C technical reports index at https://www.w3.org/TR/.
Comments regarding this document are welcome. Please file issues directly on GitHub, or send them to public-vc-comments@w3.org (subscribe, archives).
This document was published by the Verifiable Claims Working Group as an Editor's Draft.
GitHub Issues are preferred for discussion of this specification. Alternatively, you can send comments to our mailing list. Please send them to public-vc-comments@w3.org (archives).
Publication as an Editor's Draft does not imply endorsement by the W3C Membership. This is a draft document and may be updated, replaced or obsoleted by other documents at any time. It is inappropriate to cite this document as other than work in progress.
This document was produced by a group operating under the W3C Patent Policy. W3C maintains a public list of any patent disclosures made in connection with the deliverables of the group; that page also includes instructions for disclosing a patent. An individual who has actual knowledge of a patent which the individual believes contains Essential Claim(s) must disclose the information in accordance with section 6 of the W3C Patent Policy.
This document is governed by the 1 March 2019 W3C Process Document.
This guide provides some examples and resources for implementing protocols which make use of verifiable credentials, beyond those available in the core specification.
It may be useful to first familiarize yourself with the official Use Cases document, which offers a concise collection of examples of Verifiable Credentials as they may appear in everyday life, and how they may be used.
The data model specification contains the technical details about verifiable credentials. However, the data model specification does not specify any protocols for using verifiable credentials, nor any proof formats or additional identifiers upon which such protocols may depend.
When expressing statements about a specific entity, such as a person, product,
or organization, it is often useful to have an identifier for it so that others
can express statements about the same thing. The verifiable credentials
data model specification
contains numerous examples where the identifier is a
decentralized identifier,
also known as a DID. An example of a DID is did:example:123456abcdef
.
There is currently a proposed charter for a W3C Decentralized Identifier Working Group, which will put DIDs on track to become a W3C standard.
As of the publication of the verifiable credentials data model specification, DIDs are not necessary for verifiable credentials to be useful. Specifically, verifiable credentials do not depend on DIDs and DIDs do not depend on verifiable credentials. However, it is expected that many verifiable credentials will use DIDs and that software libraries implementing the data model specification will benefit from knowing how to resolve DIDs. DID-based URLs may be used to express identifiers associated with subjects, issuers, holders, credential status lists, cryptographic keys, and other machine-readable information associated with a verifiable credential.
This section is non-normative.
The following terms are used to describe concepts in this specification.
did:example:123456abcdef
.
Verification is the process a verifier or holder performs when presented with a verifiable presentation or verifiable credential. Verification includes checking the presented item against the core data model, and may also include validating the provided proof section and checking the item's status.
Conformant tooling that processes Verifiable Credentials will ensure that the core data model is verified when processing credentials.
There are many data verification languages, the following approach is one that should work for most use cases.
Protecting the integrity of content is an important component of verification. Verifiers need to have confidence that the content they rely on to verify credentials doesn't change without their knowledge. This content may include data schemas, identifiers, public keys, etc.
There are a number of ways to provide content integrity protection. A few of these are described in greater detail below.
Hashlink URLs can be used to provide content integrity for links to external resources.
A verifiable data registry can also provide content integrity protection. One example of a verifiable data registry which provides content integrity protection is a distributed ledger. This is a shared transaction record which provides mechanisms for verifying the content it stores. These mechanisms include consensus protocols, digital signatures, and verifiable data structures such as Merkle trees. These mechanisms provide cryptographic assurances that the content retrieved from the ledger has not been altered, and is complete.
There are at least two different cases to consider where an entity wants to dispute a credential issued by an issuer:
address
property is incorrect or out of date.
The mechanism for issuing a DisputeCredential
is the same as
for a regular credential, except that the credentialSubject
identifier in the DisputeCredential
property is the identifier of
the disputed credential.
For example, if a credential with an identifier of
https://example.org/credentials/245
is disputed, an entity
can issue one of the credentials shown below. In the first example, the
subject might present this to the verifier along with the disputed
credential. In the second example, the entity might publish the
DisputeCredential
in a public venue to make it known that the
credential is disputed.
{
"@context": [
"https://www.w3.org/2018/credentials/v1",
"https://www.w3.org/2018/credentials/examples/v1"
],
"id": "http://example.com/credentials/123",
"type": ["VerifiableCredential", "DisputeCredential"],
"credentialSubject": {
"id": "http://example.com/credentials/245",
"currentStatus": "Disputed",
"statusReason": {
"@value": "Address is out of date",
"@language": "en"
},
},
"issuer": "https://example.com/people#me",
"issuanceDate": "2017-12-05T14:27:42Z",
"proof": { ... }
}
{
"@context": "https://w3id.org/credentials/v1",
"id": "http://example.com/credentials/321",
"type": ["VerifiableCredential", "DisputeCredential"],
"credentialSubject": {
"id": "http://example.com/credentials/245",
"currentStatus": "Disputed",
"statusReason": {
"@value": "Credential contains disputed statements",
"@language": "en"
},
"disputedClaim": {
"id": "did:example:ebfeb1f712ebc6f1c276e12ec21",
"address": "Is Wrong"
}
},
"issuer": "https://example.com/people#me",
"issuanceDate": "2017-12-05T14:27:42Z",
"proof": { ... }
}
In the above verifiable credential, the issuer is claiming that the address in the disputed verifiable credential is wrong. For example, the subject might wrongly be claiming to have the same address as that of the issuer.
If a credential does not have an identifier, a content-addressed identifier can be used to identify the disputed credential. Similarly, content-addressed identifiers can be used to uniquely identify individual claims.
Verifiable credentials may be presented to a verifier by
using a verifiable presentation. A verifiable presentation can
be targeted to a specific verifier by using a Linked Data Proof
that includes a domain
and challenge
. This also
helps prevent a verifier from reusing a verifiable presentation
as their own.
The domain
value can be any string or URI, and the
challenge
should be a randomly generated string.
The following sample verifiable presentation is for authenticating to
a website, https://example.com
.
{ "@context": [ "https://www.w3.org/2018/credentials/v1" ], "type": "VerifiablePresentation, "verifiableCredential": { ... }, "proof": { "type": "Ed25519Signature2018", "created": "2019-08-13T15:09:00Z", "challenge": "d1b23d3...3d23d32d2", "domain": "https://example.com", "jws": "eyJhbGciOiJFZERTQSIsImI2NCI6ZmFsc2UsImNyaXQiOlsiYjY0Il19..uyW7Hv VOZ8QCpLJ63wHode0OdgWjsHfJ0O8d8Kfs55dMVEg3C1Z0bYUGV49s8IlTbi3eXsNvM63n vah79E-lAg", "proofPurpose": "authentication" } }
The Verifiable Credentials Data Model is designed around an open world assumption, meaning that any entity can say anything about another entity. This approach enables permissionless innovation; there is no centralized registry or authority through which an extension author must register themselves nor the specific data models and vocabularies they create.
Instead, credential data model authors are expected to use machine-readable vocabularies through the use of [LINKED-DATA]. This implementation guide provides examples for how to express data models using a data format that is popular with software developers and web page authors called [JSON-LD]. This data format provides features that enable authors to express their data models in idiomatic JSON while also ensuring that their vocabulary terms are unambigiously understood, even by software that does not implement JSON-LD processing.
The Verifiable Credentials data model also uses a graph-based data model, which allows authors to model both simple relationships that describe one or more attributes for a single entity and complex multi-entity relationships.
The rest of this section describes how to author extensions that build on the Verifiable Credentials Data Model.
We expect the most common extensions to the Verifiable Credentials Data Model to be new credential types. Whenever someone has something to say about one or more entities and they want their authorship to be verifiable, they should use a Verifiable Credential. Sometimes there may be an existing credential type, that someone else has created, that can be reused to make the statements they want to make. However, there are often cases where new credential types are needed.
New credential types can be created by following a few steps. This guide will also walk you through creating an example new credential type. At a high level, the steps to follow are:
So, let's walk through creating a new credential type which we will
call ExampleAddressCredential
. The purpose of this credential
will be to express a person's postal address.
First, we must design a data model for our new credential type. We know that we will need to be able to express the basics of a postal address, things like a person's city, state, and zipcode. Of course, those items are quite US centric, so we should consider internationalizing those terms. But before we go further, since we're using [LINKED-DATA] vocabularies, there is a good chance that commonly known concepts may already have a vocabulary that someone else has created that we can leverage.
If we are going to use someone else's vocabulary, we will want to make sure it is stable and unlikely to change in any significant way. There may even be technologies that we can make use of that store immutable vocabularies that we can reference, but those are not the focus of this example. Here we will rely on the inertia that comes from a very popularly used vocabulary on the Web, schema.org. It turns out that this vocabulary has just what we need; it has already modeled a postal address and even has examples for how to express it using JSON-LD.
Using the schema.org vocabulary and JSON-LD we can express a person's address like so:
{
"@context": [
"http://schema.org"
],
"type": "Person",
"address": {
"type": "PostalAddress",
"streetAddress": "123 Main St."
"addressLocality": "Blacksburg",
"addressRegion": "VA",
"postalCode": "24060",
"addressCountry": "US"
}
}
Note the above @context
key in the JSON. This @context
refers to a machine-readable file (also expressed in JSON) that provides
term definitions [JSON-LD]. A term definition maps a key or type used in the
JSON, such as address
or PostalAddress
, to a globally
unique identifier: a URL.
This ensures that when software sees the @context
http://schema.org, that it will interpret the the keys and types in the
JSON in a globally consistent way, without requiring developers to use full URLs
in the JSON or in the code that may traverse it. As long as the software is
aware of the specific @context
used (or if it uses JSON-LD
processing to transform it to some other known @context
), then it
will understand the context in which the JSON was written and meant to
be understood. The use of @context
also allows [JSON-LD] keywords
such as @type
to be aliased to the simpler type
as
is done in the above example.
Note that we could also express the JSON using full URLs, if we want to avoid using @context. Here is what the example would look like if we did that:
{ "@type": "http://schema.org/Person", "http://schema.org/address": { "@type": "http://schema.org/PostalAddress", "http://schema.org/streetAddress": "123 Main St." "http://schema.org/addressLocality": "Blacksburg", "http://schema.org/addressRegion": "VA", "http://schema.org/postalCode": "24060", "http://schema.org/addressCountry": "US" } }
While this form is an acceptable way to express the information such that it is
unambiguous, many software developers would prefer to use more idiomatic JSON.
The use of @context
enables idiomatic JSON without losing global
consistency and without the need for a centralized registry or authority for
creating extensions. Note that @context
can also have more than
one value. In this case, a JSON array is used to express multiple values, where
each value references another context that defines terms. Using this mechanism
we can first bring in the terms defined in the Verifiable Credentials Data Model
specification and then bring in the terms defined by schema.org:
{
"@context": [
"https://www.w3.org/2018/credentials/v1",
"http://schema.org"
],
...
"credentialSubject": {
"type": "Person",
"address": {
"type": "PostalAddress",
"streetAddress": "123 Main St."
"addressLocality": "Blacksburg",
"addressRegion": "VA",
"postalCode": "24060",
"addressCountry": "US"
}
},
...
}
Note, however, that each context might have a different definition for
the same term, e.g., the JSON key address
might map to a different
URL in each context. By default, [JSON-LD] allows terms in a
@context
to be redefined using a last term wins
order. While these changes can be safely dealt with by using JSON-LD
processing, we want to lower the burden on consumers of Verifiable Credentials.
We want consumer software to be able to make assumptions about the meaning of
terms by only having to read and understand the string value associated with
the @context
key. We don't want them to have to worry about terms
being redefined in unexpected ways. That way their software can inspect only
the @context
values and then be hard coded to understand the
meaning of the terms.
In order to prevent term redefinition, the [JSON-LD] @protected
feature must be applied to term definitions in the @context
. All
terms in the core Verifiable Credentials @context
are
already protected in this way. The only time that an existing term is allowed
to be redefined is if the new definition is scoped underneath another new term
that is defined in a context. This matches developer expectations and
ensures that consumer software has strong guarantees about the semantics of the
data it is processing; it can be written such that it is never confused about
the definition of a term. Note that consumers must determine their own risk
profile for how to handle any credentials their software processes that include
terms that it does not understand.
Given the above, there is at least one reason why we don't want to use
the schema.org context: it is designed to be very flexible and thus
does not use the @protected
feature. There are a few additional
reasons we want to create our own [JSON-LD] context though. First, the
schema.org context does not define our new credential type:
ExampleAddressCredential. Second, it is not served via a secure
protocol (e.g., https); rather, it uses http. Note that this
is less of a concern than it may seem, as it is recommended that all Verifiable
Credential consumer software hard code the @context
values it
understands and not reach out to the Web to fetch them. Lastly, it is a very
large context, containing many more term definitions than are necessary for our
purposes.
So, we will create our own [JSON-LD] context that expresses just those term definitions that we need for our new credential type. Note that this does not mean that we must mint new URLs; we can still reuse the schema.org vocabulary terms. All we are doing is creating a more concise and targeted context. Here's what we'll need in our context:
{ "@version": 1.1, "@protected": true, "ExampleAddressCredential": "https://example.org/ExampleAddressCredential", "Person": { "@id": "http://schema.org/Person", "@context": { "@version": 1.1, "@protected": true, "address": "http://schema.org/address" } }, "PostalAddress": { "@id": "http://schema.org/PostalAddress", "@context": { "@version": 1.1, "@protected": true, "streetAddress": "http://schema.org/streetAddress", "addressLocality": "http://schema.org/addressLocality", "addressRegion": "http://schema.org/addressRegion", "postalCode": "http://schema.org/postalCode", "addressCountry": "http://schema.org/addressCountry" } } }
The above context defines a term for our new credential type ExampleAddressCredential, mapping it to the URL https://example.org/ExampleAddressCredential. We could have also chosen a URI like urn:private-example:ExampleAddressCredential, but this approach would not allow us to serve up a Web page to describe it, if we so desire. The context also defines the terms for types Person and PostalAddress, mapping them to their schema.org vocabulary URLs. Furthermore, when those types are used, it also defines protected terms for each of them via a scoped context, mapping terms like address and streetAddress to their schema.org vocabulary URLs. For more information on how to write a JSON-LD context or scoped contexts, see the [JSON-LD] specification.
Now that we have a [JSON-LD] context, we must give it a URL. Technically speaking, we could just use a URI, for example, a private URN such as urn:private-example:my-extension. However, if we want people to be able to read and discover it on the Web, we should give it a URL like https://example.org/example-address-credential-context/v1.
When this URL is dereferenced, it should return application/ld+json by default, to allow JSON-LD processors to process the context. However, if a user agent requests HTML, it should return human readable text that explains, to humans, what the term definitions are and what they map to. Since we're reusing an existing vocabulary, schema.org, we can also simply link to the definitions of the meaning of our types and terms via their website. If we had created our own new vocabulary terms, we would describe them on our own site, ideally including machine readable Information as well.
Now we're ready for our context to be used by anyone who wishes to issue an ExampleAddressCredential!
{
"@context": [
"https://www.w3.org/2018/credentials/v1",
"https://example.org/example-address-credential-context/v1"
],
"id": "https://example.org/credentials/1234",
"type": "ExampleAddressCredential",
"issuer": "https://example.org/people#me",
"issuanceDate": "2017-12-05T14:27:42Z",
"credentialSubject": {
"id": "did:example:1234",
"type": "Person",
"address": {
"type": "PostalAddress",
"streetAddress": "123 Main St."
"addressLocality": "Blacksburg",
"addressRegion": "VA",
"postalCode": "24060",
"addressCountry": "US"
}
},
"proof": { ... }
}
Note that writing this new credential type requires permission from no one, you must only adhere to the above referenced standards.
The JSON-LD Context declaration mechanism is used by implementations to signal the context in which the data transmission is happening to consuming applications:
{
"@context": [
"https://www.w3.org/2018/credentials/v1",
"https://www.w3.org/2018/credentials/examples/v1"
],
"id": "http://example.edu/credentials/1872",
...
Extension authors are urged to publish two types of information at the
context URLs. The first type of information is for machines, and is the
machine-readable JSON-LD Context. The second type of information is for
humans, and should be an HTML document. It is suggested that the default
mode of operation is to serve the machine-readable JSON-LD Context as that is
the primary intended use of the URL. If content-negotiation is supported,
requests for text/html
should result in a human readable document.
The human readable document should at least contain usage information for the
extension, such as the expected order of URLs associated with the
@context
property, specifications that elaborate on the extension,
and examples of typical usage of the extension.
The verifiable credentials data model is designed to be proof format agnostic. The specification does not normatively require any particular digital proof or signature format. While the data model is the canonical representation of a verifiable credential or verifiable presentation, the proving mechanisms for these are often tied to the syntax used in the transmission of the document between parties. As such, each proofing mechanism has to specify whether the validation of the proof is calculated against the state of the document as transmitted, against the transformed data model, or against another form. At the time of publication, at least two proof formats are being actively utilized by implementers, and the Working Group felt that documenting what these proof formats are and how they are being used would be beneficial to other implementers.
This guide provides tables in section Benefits of JWTs and section Benefits of JSON-LD and LD-Proofs that compare three syntax and proof format ecosystems; JSON+JWTs, JSON-LD+JWTs, and JSON-LD+LD-Proofs.
Because the Verifiable Credentials Data Model is extensible, and agnostic to any particular proof format, the specification and use of additional proof formats is supported.
The Verifiable Credentials Data Model is designed to be compatible with a variety of existing and emerging syntaxes and digital proof formats. Each approach has benefits and drawbacks. The following table is intended to summarize a number of these native trade-offs.
The table below compares three syntax and proof format ecosystems; JSON+JWTs, JSON-LD+JWTs, and JSON-LD+LD-Proofs.
Feature | JSON + JWTs |
JSON‑LD + JWTs |
JSON‑LD + LD‑Proofs |
---|---|---|---|
PF1a. Proof format supports Zero-Knowledge Proofs. | ✓ | ✓ | ✓ |
PF2a. Proof format supports arbitrary proofs such as Proof of Work, Timestamp Proofs, and Proof of Stake. | ✓ | ✓ | ✓ |
PF3a. Based on existing official standards. | ✓ | ✖ | ✖ |
PF4a. Designed to be small in size. | ✓ | ✖ | ✖ |
PF5a. Offline support without further processing. | ✓ | ✖ | ✖ |
PF6a. Wide adoption in other existing standards. | ✓ | ✓ | ✖ |
PF7a. No type ambiguity. | ✓ | ✖ | ✖ |
PF8a. Broad library support. | ✓ | ✖ | ✖ |
PF9a. Easy to understand what is signed. | ✓ | ✓ | ✖ |
PF10a. Ability to be used as authn/authz token with existing systems. | ✓ | ✓ | ✖ |
PF11a. No additional canonicalization required. | ✓ | ✖ | ✖ |
PF12a. No Internet PKI required. | ✓ | ✖ | ✖ |
PF13a. No resolution of external documents needed. | ✓ | ✖ | ✖ |
Some of the features listed in the table above are debateable, since a feature can always be added to a particular syntax or digital proof format. The table is intended to identify native features of each combination such that no additional language design or extension is required to achieve the identified feature. Features that all languages provide, such as the ability to express numbers, have not been included for the purposes of brevity. Find more information about different proof formats in the next section.
proof
attributes for repudiable proofs such as Zero-Knowledge Proofs.
In that case, the JWS will not have an signature element.
proof
attributes for any type of proofs such as Proof of Work, Timestamp,
Proofs, and Proof Stake.
@context
. This means that
a verifiable credential system would rely on existing Internet PKI to a certain extend and
cannot be fully decentralized. A JWT-based system does not need to introduce this dependency.
The Verifiable Credentials Data Model is designed to be compatible with a variety of existing and emerging syntaxes and digital proof formats. Each approach has benefits and drawbacks. The following table is intended to summarize a number of these native trade-offs.
The table below compares three syntax and proof format ecosystems; JSON+JWTs, JSON-LD+JWTs, and JSON-LD+LD-Proofs. Readers should be aware that Zero-Knowledge Proofs are currently proposed as a sub-type of LD-Proofs and thus fall into the final column below.
Feature | JSON + JWTs |
JSON‑LD + JWTs |
JSON‑LD + LD‑Proofs |
---|---|---|---|
PF1b. Support for open world data modelling. | ✖ | ✓ | ✓ |
PF2b. Universal identifier mechanism for JSON objects via the use of URIs. | ✖ | ✓ | ✓ |
PF3b. A way to disambiguate properties shared among different JSON documents by mapping them to IRIs via a context. | ✖ | ✓ | ✓ |
PF4b. A mechanism to refer to data in an external document, where the data may be merged with the local document without a merge conflict in semantics or structure. | ✖ | ✓ | ✓ |
PF5b. The ability to annotate strings with their language. | ✖ | ✓ | ✓ |
PF6b. A way to associate arbitrary datatypes, such as dates and times, with arbitrary property values. | ✖ | ✓ | ✓ |
PF7b. A facility to express one or more directed graphs, such as a social network, in a single document. | ✖ | ✓ | ✓ |
PF8b. Supports signature sets. | ✖ | ✖ | ✓ |
PF9b. Embeddable in HTML such that search crawlers will index the machine-readable content. | ✖ | ✖ | ✓ |
PF10b. Data on the wire is easy to debug and serialize to database systems. | ✖ | ✖ | ✓ |
PF11b. Nesting signed data does not cause data size to double for every embedding. | ✖ | ✖ | ✓ |
PF12b. Proof format supports Zero-Knowledge Proofs. | ✖ | ✖ | ✓ |
PF13b. Proof format supports arbitrary proofs such as Proof of Work, Timestamp Proofs, and Proof of Stake. | ✖ | ✖ | ✓ |
PF14b. Proofs can be expressed unmodified in other data syntaxes such as YAML, N-Quads, and CBOR. | ✖ | ✖ | ✓ |
PF15b. Changing property-value ordering, or introducing whitespace does not invalidate signature. | ✖ | ✖ | ✓ |
PF16b. Designed to easily support experimental signature systems. | ✖ | ✖ | ✓ |
PF17b. Supports signature chaining. | ✖ | ✖ | ✓ |
PF18b. Does not require pre-processing or post-processing. | ✖ | ✖ | ✓ |
PF19b. Canonicalization requires only base-64 encoding. | ✖ | ✖ | ✓ |
Some of the features listed in the table above are debateable, since a feature can always be added to a particular syntax or digital proof format. The table is intended to identify native features of each combination such that no additional language design or extension is required to achieve the identified feature. Features that all languages provide, such as the ability to express numbers, have not been included for the purposes of brevity.
@context
property. JSON has no such feature.
The Verifiable Credentials Data Model is designed to be compatible with a variety of existing and emerging digital proof formats. Each proof format has benefits and drawbacks. Many proof formats cannot reveal only selected attribute values from a verifiable credential; they can only reveal all (or none).
Zero-Knowledge Proofs (ZKPs) are a proof format that enables privacy-preserving data-minimization features in verifiable presentations, such as selective disclosure and predicate proofs.
Selective disclosure is the ability of a holder to reveal a subset of the attributes of a verifiable credential in a verifiable presentation. A presentation based on zero-knowledge proof mechanisms only contains those attributes and associated values that are required to satisfy the presentation requirements.
Zero-knowledge predicate proofs are a type of proof associated with an attribute. Predicate proofs include comparisons, such as "greater than", "less than", "not equal", "range", "set membership", and "set non-membership". Predicate proofs can be constructed without requiring the issuer to create special fields, such as "age-under-18", "age-over-21", or "age-over-60", in the verifiable credential at the time the credential is issued. For example, if a holder has a credential with a "birth-date" claim, the holder can create a predicate proof based on "birth-date" in the verifiable presentation. A predicate value derived from "birth-date" in the verifiable credential can cryptographically prove to the verifier that the holder's age is greater (or less) than a specified number, without revealing the holder's "birth-date".
Verifiable credentials based on zero-knowledge proof mechanisms are also quantum-resistant after presentation.
Drawbacks of zero-knowledge proof mechanisms include that they are more complex and may require larger proofs than some other proof mechanisms.
Entities that use verifiable credentials and verifiable presentations should follow protocols that enable progressive trust. Progressive trust refers to enabling individuals to share information about themselves only on an as needed basis, slowing building up more trust as more information is shared with another party.
Progressive trust is strongly related to the principle of data minimization, and enabled by technologies such as selective disclosure and predicate proofs. We encourage the use of progressive trust as a guiding principle for implementers as they develop protocols for issuers, holders, and verifiers.
Data minimization is a principle that encourages verifiers to request the minimum amount of data necessary from holders, and for holders to only provide the minimum amount of data to verifiers. This "minimum amount of data" depends on the situation and may change over the course of a holder's interaction with a verifier.
For example, a holder may apply for a loan, with a bank acting as the verifier. There are several points at which the bank may want to determine whether the holder is qualified to continue in the process of applying for the loan; for instance, the bank may have a policy of only providing loans to existing account holders. A protocol that follows the principle of data minimization would allow the holder to reveal to the verifier only that they are an existing account holder, before the bank requests any additional information, such as account balances or employment status. In this way, the applicant may progressively entrust the bank with more information, as the data needed by the bank to make its determinations is requested a piece at a time, as needed, rather than as a complete set, up front.
Selective disclosure is the ability of a holder to select some elements of a verifiable credential to share with a verifier, without revealing the rest. There are several different methods which support selective disclosure, we provide two examples:
Another technique which may be used to support progressive trust is to use predicates as the values of revealed claims. Predicates allow a holder to provide True/False values to a verifier rather than revealing claim values.
Predicate proofs may be enabled by verifiable credential issuers
as claims, e.g., the credentialSubject may include an
ageOver18
property rather than a birthdate
property. This would allow holders to provide proof that they are
over 18 without revealing their birthdates.
Certain signature types enable predicate proofs by allowing claims from a
standard verifiable credential to be presented as predicates. For
example, a
Camenisch-Lysyanskaya signed verifiable credential that contains a
credentialSubject
with a birthdate
property may
be included in a verifiable presentation as a derived credential that
contains an ageOver18
property.
The examples provided in this section are intended to illustrate some possible mechanisms for supporting progressive trust, not provide an exhaustive or comprehensive list of all the ways progressive trust may be supported. Research in this area continues with the use of cutting-edge proof techniques such as zk-SNARKS and Bulletproofs, as well as different signature protocols.
A draft report by the Credentials Community Group on data minimization may also be useful reading for implementers looking to enable progressive trust.
The W3C Verifiable Claims Working Group has produced a test suite in order for implementers to confirm their conformance with the current specifications.
You can review the current draft implementation report, which contains conformance testing results for submitted implementations supporting the Verifiable Credentials Data Model specification.