-
Notifications
You must be signed in to change notification settings - Fork 111
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Do we have to introduce the Credential
class in the VCDM vocabulary?
#1044
Comments
Thank you for filing this. Still digesting it. Similar to the argument regarding media types, we should avoid creating new RDF classes if we don't need them. |
As a personal opinion (i.e., with my staff contact's hat put down) I would be strongly in favour of the first alternative, ie, the subclassing approach. It keeps the vocabulary simple, and it corresponds, ontologically, to the fact that a verifiable credential is a credential... |
IFF we introduce the
That said, my opinion is that we should NOT introduce the term. I'm in favor of only having Let me elaborate on why I think we should only have a single term. We can informatively refer to something as a The conclusion I arrive to is that there already exists a brand (which is also a normative term) called Furthermore, I would suggest we replace the use of the term |
I would prefer not to make implementations more complicated by having to use |
@dlongley just to understand what you propose:
I do have a clear opinion on (1) (which is a "yes!") but I do not have a clear opinion on (2), so I let you guys decide on that. I am not a VC implementer, nor am I a familiarity with that community, and I am obviously biased by my background... |
Yes, to 1 and 2 -- I'm trying to find a middle ground where we can do the vocabulary properly and keep implementations simple. |
I'll be saying similar things to the following in a few threads, I think, as overlapping topics are being covered in multiple issues... We must remember that classes and subclasses (a/k/a types and subtypes) do not necessarily require differentiation in their Media Types, and in fact, some subtypes SHOULD NOT have a Media sub-Type — such as the I am firmly convinced that we need This comment does not represent completed thoughts, but I thought it more important to start others thinking about the same things, than to finish the picture myself. |
The issue was discussed in a meeting on 2023-02-28
View the transcript1. Add normative requirements regarding media type and proof (pr vc-data-model#1014)See github pull request vc-data-model#1014. See github pull request vc-data-model#1034. See github issue vc-data-model#1044. Brent Zundel: There is a long conversation in the PR, goal of this meeting is to hash out what different sides of debate are, and can then try to come to proposals, recommendations on how to move forward.. Manu Sporny: There are a couple of threads for this discussion. One of the threads is "hey, we should have a media type for unsecured credentials and we should have one for secured ones. Those are the two classes we should have.". Michael Prorock: I think that's a reasonably good summary, in my mind, it's a more fundamental question. What is a credential? What makes it a verifiable credential?. Dave Longley: I think it's good to avoid confusion where we can, we have to be careful about avoiding confusion when we're talking about secured vs. unsecured or trusted vs. untrusted data... the recipient of the data needs to have an expectation about what they're receiving. They can't just accept whatever the sender sends, that opens the door to potential vulnerabilities.. David Waite: Some of this may be defining the behaviour when you have multiple proofs by default, I can remove one of the proofs and it's still verifiable, just with less mechanisms.. Michael Prorock: The PR here is explicit around one line related to Manu Sporny: So I want to agree with what David Waite was saying.. Dave Longley: media types are not necessarily the right tool to make sure that something is an input to an API. The media type is a way to identify the type of content and how it would be parsed and used, regardless of what API you're using it in. It's a more encompassing thing, not for just one particular use case, one particular API, it's not the right tool for accomplishing that..
Dave Longley: That said, APIs have their own shape, can provide their own restrictions, you can do that, that's not a problem and that might be the right way to define that, you can do that via API schemas to accomplish that goal.. Kristina Yasuda: Manu's comment confused me. I do not understand the concept of top level, secondary level proofs, one of the things we did in data model v2 is we separated data model in how we sign/secure it. The notion that something that conceptually is not supposed to be signed can have this proof is very confusing to me.. Michael Prorock: Big +1 to what Kristina said, building on that, we have a good model if we accept this PR, core data model defines what a credential is, and how different specifications might process that... what's expected, in VC-JWT there is a clean way of specifying media types, what to expect when, JWS, or something COSE related, since we have a nice data integrity spec, perhaps we should put media types w/ proofs in a credential, people know how to deal with that information.. Manu Sporny: To address Kristina's concern. We have a concept here -- and JWTs deal with it differently. With Data Integrity proofs, you can have documents that nest other documents and each can nest proofs at every layer..
Manu Sporny: Saying Dave Longley: big +1 to what manu said... if we moved proof into data integrity, it would further undercut case for restricting Kristina Yasuda: To clarify -- not questioning legitimacy of use case where there are nested data integrity proofs -- what I'm not understanding is credential that is conceptually not supposed to be signed, including a proof property? That's what clearly separates credential from verifiable credential. Let's not completely remove proof from data model, remove it from section 4 to section 6..
Kristina Yasuda: Imagine a JSON structure that includes proof property... and that is signed by JWS... if that enters JWS processor, that doesn't understand proof claim, it'll ignore it. In which case, signature is entirely being ignored, which I'm concerned about. Is there a way to resolve that? Happy to hear solutions.. Michael Prorock: No one is saying these are not valid use cases, we want a clear and valid media type. David Waite: In the spec we talk about embedded proofs and external proofs, way to state the same thing... embedded proof is a way to extract proof and recanonicalize to create an external proof over the document. It comes down to giving recommendations --- if one proof is chaining, pointing into another, you cannot express outer proof w/o inner one, but you can strip off outer proof, so when people embed a data integrity protected VC inside a JWT, they need to understand that they're requiring twice as much security processing logic... that may affect full stack decisions, or they could just discard the JWT and send credential and data integrity around and they need to decide if it's appropriate or not. If we do have it, we should have a SHOULD NOT with guidance.. Dave Longley: There are going to be many applications that can accept a credential whether or not it has a proof attached to it, important that base media type supports that... if there are other applications that want to have a media type that specifically says "this property is not allowed in this media type" - I think we can do that, but I recommend against it, I don't think it's a good idea. I don't think we should call that out on the base media type. Maybe have base media type to be superclass of other things, someone could create a media type for their other applications, can't have specific property..
Dave Longley: "What if this verifier receives something where a signature has been stripped?" -- verifiers need to know what to expect from a holder. They will know what proofs they need to look for, they need to know which issuers to trust, how many signatures to expect, etc... we should remember that we're defining a base data model here, there are things that people don't necessarily process in a credential... base media type that's a super class allows that to happen, I don't think there's a problem there..
Kristina Yasuda: yes, but what they accept is up to them. Manu Sporny: I think we need to look at the PR. The PR is specifically talking about the
Manu Sporny: So I think the thing you mentioned is a different conversation and that I agree with you more over there, than on this PR. This PR says, we're going to single out this one property and makes it illegal..
Manu Sporny: I think we're trying to use media types to signal things that we shouldn't rely on, it gives power to the attacker..
Michael Prorock: I don't think anyone is disagreeing on the multiple layers on security checks, not trusting inputs, I would hope all of us in this group are familiar with those concepts..
Michael Prorock: What I'm concerned about is saying that something should not have a proof in any way shape or form, perhaps from a consensus standpoint we end up in SHOULD NOT. If we want to think about a variety of things, no one here wants a proliferation of media types for every options, No one is asking for a proliferation of business rules defined in the spec. If it is implicitly confusing that receives a proof in it, or embedded in a VC-JWT, what proof type comes first. If we don't have a clear way of saying: "Don't do this, you're going to confuse the user"... it's highly concerning to me. If we leave it up to verifier, certain issuers are going to assume one type of security model might be required w/o clean mechanism to know that they're doing that. Let's try to get explicitly clear about what a credential is before it becomes a VC and then be very clear about that as well.. Tobias Looker: I'm still catching up on this issue, so might have perspective that's invalid -- my interpretation of text in PR doesn't insinuate that it makes embedded proofs illegal, media type doesn't establish any semantics around inclusion of property of what it means. If I sent application/json, and data is customer record, that is at a different layer semantically. Embedded proof might have something secured, media type isn't going to communicate presence or processing logic to do anything w/ that..
Ted Thibodeau Jr.: Media types don't do these things... media types don't say "in this structure of file you can only have X field name". Media types give you the structure of the file so you can deal w/ it's contents. If you feed a .zip archive to Excel, it's going to choke because it doesn't know how to deal w/ that content..
Ted Thibodeau Jr.: Vice versa, unzip cannot do anything for you with the contents of an excel file... it's not the structure of the document it works on, the structure is the thing that matters here. Subtypes in the mediatype universe are limited not in what fields they can have and the contents of what they could be... bigger type might allow larger number of rearrangements, smaller more focused might allow less..
Ted Thibodeau Jr.: Media types don't care about proofs, or business logic, or anything like that. Trying to make them do that job, we're going to break all sorts of security models. It don't work that way..
Ted Thibodeau Jr.: I've said in a number of times, a number of places, people don't seem to understand how media types work, if you don't understand how this stuff works, and we try to spec with it, we're going to break something.. Tobias Looker: Further the point that I'm making, don't think media type should rule out in an extensible data model technology whether or not the member of an element should /shouldn't make something illegal. I don't think media type should reach into the data representation technology and says "this should never exist". I think that messes w/ data extensibility model in JSON..
Tobias Looker: The media type doesn't convey that, media type doesn't tell you anything about what the media type tells you that... it could just be a string w/ some other meaning attached to it. That's all I take the language to mean in this PR. It doesn't communicate anything about the presence of an embedded proof or not.. Manu Sporny: +1 to tplooker, Tallted.. David Waite: One of the ongoing concerns, we're trying to define an extensible data model to use it in ways that we haven't imagined... even extension points we have, like
Michael Prorock: Is there an approach that might work? If media type is used, embedded proof must be ignored by processor by verifier? This is a reasonably complex thing we're trying to say.. Kristina Yasuda: I think we double clicked on statements meant by tobias and tallted -- JWT registered
Brent Zundel: Jump on PR and try to refine some language..
Brent Zundel: See everyone on the call tomorrow.. |
I am opposed to defining RDF that has no impact or use for implementers. I am opposed to an RDF type called |
I agree with @OR13 that having an RDF type called |
@TallTed There is no Your assertion that Only I assume eventually this issue will become a PR to create the subtype relationship or it will be closed. That PR would need to modify this vocabulary: https://www.w3.org/2018/credentials/ |
I am not sure what the controversy is all about, @OR13 @TallTed. This issue asks whether there is a need for a separation between the |
If I am in favor of creating clarity if the classes will have some use to implementers, and if they do not create further semantic confusion. Option 1:"Credential": {
"@id": "https://www.w3.org/2018/credentials#Credential",
"@context": {
"@protected": true,
"id": "@id",
"type": "@type",
"credentialSchema": {
"@id": "https://www.w3.org/2018/credentials#credentialSchema",
"@type": "@id"
},
"credentialStatus": {
"@id": "https://www.w3.org/2018/credentials#credentialStatus",
"@type": "@id"
},
"credentialSubject": {
"@id": "https://www.w3.org/2018/credentials#credentialSubject",
"@type": "@id"
},
"description": {
"@id": "https://schema.org/description",
"@type": "http://www.w3.org/2001/XMLSchema#string"
},
"evidence": {
"@id": "https://www.w3.org/2018/credentials#evidence",
"@type": "@id"
},
"holder": {
"@id": "https://www.w3.org/2018/credentials#holder",
"@type": "@id"
},
"issued": {
"@id": "https://www.w3.org/2018/credentials#issued",
"@type": "http://www.w3.org/2001/XMLSchema#dateTime"
},
"issuer": {
"@id": "https://www.w3.org/2018/credentials#issuer",
"@type": "@id"
},
"name": {
"@id": "https://schema.org/description",
"@type": "http://www.w3.org/2001/XMLSchema#string"
},
"proof": { // proof is included here....
"@id": "https://w3id.org/security#proof",
"@type": "@id",
"@container": "@graph"
},
"refreshService": {
"@id": "https://www.w3.org/2018/credentials#refreshService",
"@type": "@id"
},
"termsOfUse": {
"@id": "https://www.w3.org/2018/credentials#termsOfUse",
"@type": "@id"
}
}
}, Option 2"Credential": {
"@id": "https://www.w3.org/2018/credentials#Credential",
"@context": {
"@protected": true,
"id": "@id",
"type": "@type",
// proof has been removed here.
"credentialSchema": {
"@id": "https://www.w3.org/2018/credentials#credentialSchema",
"@type": "@id"
},
"credentialStatus": {
"@id": "https://www.w3.org/2018/credentials#credentialStatus",
"@type": "@id"
},
"credentialSubject": {
"@id": "https://www.w3.org/2018/credentials#credentialSubject",
"@type": "@id"
},
"description": {
"@id": "https://schema.org/description",
"@type": "http://www.w3.org/2001/XMLSchema#string"
},
"evidence": {
"@id": "https://www.w3.org/2018/credentials#evidence",
"@type": "@id"
},
"holder": {
"@id": "https://www.w3.org/2018/credentials#holder",
"@type": "@id"
},
"issued": {
"@id": "https://www.w3.org/2018/credentials#issued",
"@type": "http://www.w3.org/2001/XMLSchema#dateTime"
},
"issuer": {
"@id": "https://www.w3.org/2018/credentials#issuer",
"@type": "@id"
},
"name": {
"@id": "https://schema.org/description",
"@type": "http://www.w3.org/2001/XMLSchema#string"
},
"refreshService": {
"@id": "https://www.w3.org/2018/credentials#refreshService",
"@type": "@id"
},
"termsOfUse": {
"@id": "https://www.w3.org/2018/credentials#termsOfUse",
"@type": "@id"
}
}
}, The "controversy" is some working group members appear to want to have the word "credential" and "verifiable credential" apply to the exact same bytes. Other working group members feel this is confusing and undermines the meaning of both terms. This confusion is playing out in "media types", "spec definitions" and "rdf classes". @dlongley @msporny Do you think adding option 1 would help clarify your postion that "credential" can have a "proof?... Do you agree we should attempt to define "Credential" in RDF? |
I am most inclined to drop Whether or not it's verifiable is not a question of its structure, which goes to media type, but a question of the bits held in that structure, which goes to business logic. It may not be worth having a media type for this at all. |
@OR13 wrote:
I don't think anyone is saying "would"... folks seem to be saying "could"... because it's an open world model... any subject can be associated with any predicate unless there is a higher level rule that says it shouldn't... but that's not enforced at the RDF or JSON-LD layer... it's enforced at the VC Data Model layer. So, for example, if we are producing a JSON-LD Context for IOW, we were explicit in conceptually differentiating a
I think we should define We should separate at least three of the discussions that are happening here:
I'll try to provide thoughts on each one separately:
We make the distinction between
I don't think we have anyone using As such, I don't see a need to put this in the base JSON-LD Context... but we shouldn't prevent someone from creating their own JSON-LD Context that uses the concept. Perhaps when VC v3.0 rolls around, there'll be a set of use cases that demonstrate why having
Same argument as above... I expect the answer to be: "It's not useful at this point in time other than to convey the logical data model for the ecosystem". So, to summarize:
... with the caveat that I might feel differently about this next week. :P |
@TallTed wrote:
I think I'm inclined to go the other way, @TallTed. Let's define
:) I'd rather optimize for what developers will be working with most of the time, which is to use and express verifiable credentials... the whole concept of a To answer the question of "Well, then what media type do you send an HTTP endpoint to add a proof to a credential" could be: |
You are presenting two JSON-LD
The vocabulary/ontology is there to clarify our thoughts, first of all, and I would not underestimate that. But, from a practical point of view, if the vocabulary is used as an ontology for reasoning in a Linked Data context, an RDFS/OWL reasoner would deduce, when seeing a
This ship may have sailed already... but I sympathize with your opinion. The only thing this issue says: if we do make this strong separation between credentials and verifiable credentials conceptually, the vocabulary should reflect that (at least in my view). If we decide that we keep
I tend to agree with you, but I am not a VC implementer... |
I think with a In the spec with the caveat that the "proof" can be "embedded" or "external" this aligns with the term "verifiable credential". We need to be careful with
I think this is where the strongest disagreement exists. There are 2 considerations:
As a general rule, a new RDF type should be used when there is new information to represent. I still don't understand what "new information" would exist, between "Credential" and "VerifiableCredential"... the current arguments in favor of allowing "proof" in "Credential" make me believe there is no new information, and we should therefore NOT define "Credential". |
I think I would be fine with us dropping any formal discussion of "Credential"/"credential" and keeping all of that as informal discussion in the spec. This would include changing To emphasize, it would be vital that this would not undo other decisions and create more work for the WG -- the idea here is to simplify and reduce work. So if the above would do that and we can get consensus around it, then I'd be for it. |
Change that I might be OK with Just as we don't know every use to which verifiable credentials may be put, I don't believe we know every use to which unverifiable credentials may be put, and I want to preserve sufficient flexibility that another "thing" won't be required to satisfy those unverifiable credential use cases.
I'd be fine with changing most, probably all, instances of |
In my opinion the confusion between credential and verifiableCredential has led to issues around which metadata was tied to the credential and which was tied to the verifiableCredential. So the validity period of the credential became confused with the validity period of the cryptographic proof, whilst the ID of the credential became confused with the ID of the proof/signature. Clearly Orie's Option 1 above continues this confusion by inserting a proof property into a credential. The credential does not have a proof property. If it does then it is by definition verifiable, so is a verifiableCredential |
I have set up a PR (#1057) to focus the discussion. The possible changes (or not) on media types or context files are, though related, separate issues... |
A The presence of the |
The spec sorta disagrees with this point, though I admit that I have seen this part of the spec consistently disputed by WG members.
Note the use of the MUST... which is normative, and requires a "test". Perhaps the spec text is so poor, we must admit that it is never interpreted consistently. |
This does not require that such a proof mechanism be expressed via a
I will concede this possibility, and continue to strive for better text, toward more consistent (though perhaps never perfectly so) interpretation, particularly but not only because we are actively working on a v2 that is generally if not universally expected to improve on v1. |
100% agree... I think the problem is that it is not clear to the WG if a "well formed" "proof" property is sufficient to satisfy the MUST. The problem with this ambiguity is:
...
|
I tend to disagree. Even if a verifiable credential has an appropriate value, the credential could still have been revoked and is therefore not verifiable (for example, an imposter could have stolen the issuer's private key, issued the VC, and then the issuer, upon finding out the theft, revokes all issued VCs). So I maintain that a credential with a proof property is a verifiable credential. The proof property may be badly formatted, null, or use a weak algorithm with known flaws. Nevertheless it is verifiable, but the result of the verification process will yield the result of positive or negative verification. |
p.s. Verifiable does not mean verified |
Yes, I tend to agree with @David-Chadwick here as well. It seems as if talking about a However, talking about a I'm increasingly doubtful that normatively formalizing a |
The issue was discussed in a meeting on 2023-04-12
View the transcript4.1. Do we have to introduce the
|
It's not going to make much progress with me. A verifiable something is something which can be secured, to the extent that "securing" means "providing means by which to confirm that its content has not been tampered with, and to discover its issuer". Specific use cases may choose to use weak tools of various kinds, and still work with (weakly) verifiable credentials. The full structure of a VC can be complied with, and the V can always fail, and the document is still a VC, to my mind. What happens with the business logic thereafter is beyond our remit. |
:)
I'm not sure that's a useful definition... anything can be secured, so if that's your definition, it applies to anything, which makes the distinction not worth much. I'd argue that one of the things that makes the work this group is doing important is the notion that we're not just saying "anything can be secured"... we're saying: "We expect the VCDM to be secured in these normative ways."
Yeah, that's exactly the sort of slippery slope I'd like us to stay away from, because we can already see vendors trying to rebrand their "weakly verifiable credentials" as "verifiable credentials". There's an active dilution in the sort of verifiability and interoperability that we, as a WG, expect... and that's the thing I'm taking issue with.
Slippery slope... I get what you're saying, and don't entirely disagree with it... it's how vendors will twist your intention that worries me. Can you think of some clauses that would make it harder for vendors to twist your intention? PS: This is neither here nor there for this particular issue, it's marked pending close and should be closed. @TallTed I'm wondering if we need a new issue for whatever it is that we're discussing here. :) |
Much like the DID Rubric, I think there are some number of attributes of VCs which represent tradeoffs relevant to different deployments/use-cases. It's appropriate for us to make it as easy as possible for end users to evaluate the VCs from various vendors, and determine whether the strength of their signatures, encryption, etc., is sufficient for their comfort. Hopefully, there will be more than one VC implementation vendor vying for each deployment scenario, and the stronger will win out. |
Though some additional comments have been made, no objections have been raised since being marked |
(This discussion may belong to the comment thread of #1014, but it is not commenting on the main line of the discussion. I have therefore decided to create a separate issue.)
As a result of the introduction of
credentials+ld+json
there is now a discrepancy between the media types used in the spec and the vcdm vocabulary. I do not think that is healthy.At present, there is no class for a
Credential
in the vocabulary (although it is there between the lines, i.e., in the term definitions). We only have aVerifiableCredential
term. Now that we have a a separate media type for credentials, i.e., a (non-verifiable) credential is now a separate "thing", we may want to consider introducing a separateCredential
class to the vocabulary.However, if we do this, we have several issues that we have to consider. These issues reflect the discussions we have in #1014. (Note that this is not only boring question of RDF; the vocabulary is a (simple) ontology, i.e., it forces us to pin down the exact relationships of the various terms we are using.)
The fundamental question is: is a
VerifiableCredential
a subclass ofCredential
or not? This is, essentially, the counterpart of the question whether (if we go down that route) we would haveverifiable+credential+ld+json
orverifiable-credential+ld+json
, respectively. The alternatives on the vocabulary are:VerifiableCredential
is a subclass ofCredential
From the vocabulary point of view, this is a relatively simple thing. Most properties (
credentialStatus
,validFrom
, etc.) haveCredential
as a domain; by virtue of subclassing using those terms onVerifiableCredential
instances is perfectly fine.One would be tempted to refer to
proof
as the outlier, but the domain of that property, which is defined in the Security Vocabulary is not defined explicitly, probably because the idea is that the termproof
could be used on other concepts than credentials. I.e., even if we introduce a restriction whereby a proof must not be used on aCredential
, that statement may remain "outside" the formal ontology. (Alternatively, there may be some complicated OWL2 statement that would lead to a contradiction if proof was used on aCredential
, but I am not sure it would be worth it; it would probably be of a form that simple OWL2 reasoners could not handle, so would be ignored in practice).VerifiableCredential
is not a subclass ofCredential
From a vocabulary point of view, what it would mean is that all aforementioned properties would have, as domain definition, a disjunction, something akin to "
VerifiableCredential
orCredential
". Which is fine. However, a further question is: areVerifiableCredential
andCredential
disjoint? It certainly feel like this would be the case; luckily, OWL can express that easily, the only practical obstacle is that theyaml2vocab
script we use should be extended to introduce such extra restriction (but that can be solved).Note that the introduction of
Credential
may affect the examples in the spec which, for now are all of the form:which may have to use
Credential
instead. But, I believe, by virtue of havingcredentials+ld+json
separately this makes sense in any case...@dlongley @msporny @OR13 @mprorock @brentzundel
The text was updated successfully, but these errors were encountered: