Comments (10)
The path
component is used to locate a resource within a DID document. It is not used in resolving the DID Document itself.
DIDs are resolvable to DID documents.
A DID URL extends the syntax of a basic DID to incorporate other standard URI components such as path, query, and fragment in order to locate a particular resourceβfor example, a cryptographic public key inside a DID document ...
from did-method-web.
That looks plausible to me.
Including the service
in the DID document and referencing in the query
would be a method-agnostic approach that could easily add value to a variety of future implementations.
from did-method-web.
The DID core specification does not allow the path
component to be used as indicated in your examples.
If, theoretically, the name of a JSON file were allowed, this:
did:web:<domain>:v1/schema/<checksum>.json
would need to be represented this way:
did:web:<domain>:v1:schema:<checksum>.json
Ultimately, though, it would seem that the identifiers are intended to represent resources other than DID documents, which is likely to draw criticism.
I had a related use case in which I wanted webservers to host human readable content and DID documents on the same HTTPS URL, using content negotiation based on the content type header to select the proper resource to return. I used a dedicated method to support that use case.
from did-method-web.
Thanks for your input. We can definitly swap the path seperators for colons as specified.
Indeed, we are looking to represent objects specific to the AnonCreds spec using the did:web
method. These ojects are currently documented in the did:indy|sov|cardano|cheqd
methods thanks to recent work from respective communities and WG.
We are reaching out to see if there is such a concept in the did:web
specification currently or if this use case would ultimately need to be documented on the AnonCreds spec for contextual use with did:web
URI's. We are also looking to be considerate of existing standards for ease of implementation.
Could you provide more details on how you went about the dedicated method you are referring to? Is there any documentation available?
These objects are not meant for human readability but machine credential lifecycle management.
from did-method-web.
@gribneau the did core spec does make use of "/' for path representation if I understand correctly (see EXAMPLE 2), could you elaborate why you believe it's wrong in my example?
from did-method-web.
Could you provide more details on how you went about the dedicated method you are referring to? Is there any documentation available?
The method is here:
https://vpsqr.com/did-method-psqr/v1/
The intended use case is here:
https://vpsqr.com/did-psqr/v1/
And the resolver is here:
https://github.com/public-square/psqr-did-resolver
from did-method-web.
The
path
component is used to locate a resource within a DID document. It is not used in resolving the DID Document itself.DIDs are resolvable to DID documents.
A DID URL extends the syntax of a basic DID to incorporate other standard URI components such as path, query, and fragment in order to locate a particular resourceβfor example, a cryptographic public key inside a DID document ...
I think that the example given right after the ellipsis is relevant here:
..., or a resource external to the DID document.
AnonCreds objects are resources associated to the DID and IMHO can apply to this definition. Probably, the initial question (What is the most appropriate way to resolve other documents than did.json?) was not properly formulated or led to confusions.
In these AnonCreds methods @PatStLouis is referring to, there is a single DidDocument associated to the DID (in the case of this did:web method, it would be a JSON file present at host/.well-known/did.json
), while a DID URL is used to identify the objects related to that DID (for instance did:web:host/anoncreds/v1/schema/uniqueObjectId
or did:web:host/resources/uniqueObjectId
). As these AnonCreds objects do have a JSON representation, it might be convenient to threat them in the same way than the DidDocument and maybe that's why the original question referred to them as documents.
If we consider correct using a DID URL and a path (TBD) to identify these resources, I think the main question here is how, in practice, a 'did:web resource resolver' would retrieve them, in a similar fashion it did:web resolvers already do with the DidDocument. We have some ideas for the specific case of AnonCreds, but it would be interesting to know if it could be possible to have a generic way of retrieving resources using did:web so the case can be generalized.
from did-method-web.
AnonCreds objects are resources associated to the DID and IMHO can apply to this definition.
That might gain support. DID:WEB does not currently use either path
or query
. The fragment
often refers to an element within the DID document, frequently a public key.
Given the resolution of the DID itself to an https url, including a path, it might be more intuitive to use the query component.
from did-method-web.
Interesting. Providing a service + endpoint in the did document and use a service
+ relativeRef
query would be the most appropriate then if I understand?
ex:
did:web:{domain}?service=anoncreds&relativeRef=/schema/{objectID}
or
did:web:{domain}?service=ressources&relativeRef=/{objectID}
from did-method-web.
Closing this as, asked and answered, but feel free to reopen or raise a new issue if you have more questions.
from did-method-web.
Related Issues (20)
- Canonical URL algorithm needed for did:web `id` field HOT 3
- Deny off-domain redirects HOT 1
- replace owner with controller? HOT 1
- Register Well-Known URI HOT 1
- Is historical query out of scope of this spec? Is it standardized anywhere else? HOT 7
- RFC: Proposal to standardize email to DID translation HOT 4
- by creating DID in this method we can verify from third party ?? HOT 11
- Did web method support Ed25519?? HOT 2
- Encoding of tilde (`~`) HOT 1
- Support "file" not just "directory" paths HOT 3
- User component of a URL HOT 6
- Are did:webs that redirect another domain's did:web ok? HOT 1
- UTS-46 and WHATWG
- Require email for editors
- Can we mark this as final? HOT 3
- Resolver should check resolved document (ID) matches the expected one
- Clarify integrity protection / use of hashlinks HOT 1
- Is there any usecase or relevant usage scenarios, methods, or examples about did:web method? HOT 1
- Subpaths under /.well-known
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from did-method-web.