-
Notifications
You must be signed in to change notification settings - Fork 248
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
universal resolver does not return the same format as aca-py native resolve functionality #260
Comments
Thanks.. The Universal Resolver resolves did:sov using the corresponding driver (uni-resolver-driver-did-sov). As far as I know the latest specification is https://sovrin-foundation.github.io/sovrin/spec/did-method-spec-template.html. I'd need more time to analyze whether the spec, or the Universal Resolver driver, or the aca-py implementation is the problem here. Do you have any insight into this? As a separate note, Universal Resolver drivers should preferably re-use existing tools rather than implement DID methods themselves. So we could replace the current Universal Resolver did:sov driver with a thin wrapper around aca-py. |
We'll dig into the ACA-Py resolution. @peacekeeper is correct that the correct response should be based on the latest DID Method specification for @andrewwhitehead -- could you please take a look at what is in the ACA-Py implementation. Thanks |
@peacekeeper @martinMustermann @swcurran The reason why we have here two service endpoints is that the Bosch Business Partner Agent using an own concept called Public Profile. So this is a more specific problem to the BPA and other implementations. Since the BPA also leverages the ACaPy under the hood. It's more interesting now how to solve this with different Controllers or Agents and the problem of resolving it. |
@solidnerd Interestingly enough the BPA's public profile endpoint is successfully returned by ACA-Py.
The exception occurs when we try to call this endpoint /didexchange/create-request. In this case we are using universal resolver plugin with ACA-Py. As explained above, due to the different response format (i.e. missing id field) an exception is raised in ACA-Py. Here are steps to reproduce this issue for better understanding:
2. Then call this endpoint using swagger /didexchange/create-request with any cross-ledger indy based DID. In this case we use the above mentioned DID (did:sov:idu:6iHBriJn1DVJt3AjLEuHYL). The following exception occurs:
This exception does not occur when we are using classic ACA-Py (without universal resolver plugin) as the response of DID resolution contains the id field. |
I tried to resolve this DID 'did:sov:idu:6iHBriJn1DVJt3AjLEuHYL' in https://dev.uniresolver.io/ (like this https://dev.uniresolver.io/1.0/identifiers/did%3Asov%3Aidu%3A6iHBriJn1DVJt3AjLEuHYL) and I get a DIDDoc response.
And on the other hand, I set up an aca-py agent on IDunion and try to resolve the same DID as above (did:sov:6iHBriJn1DVJt3AjLEuHYL) and I get the following response back:
{ "@context":[ "https://www.w3.org/ns/did/v1" ], "id":"did:sov:6iHBriJn1DVJt3AjLEuHYL", "verificationMethod":[ { "id":"did:sov:6iHBriJn1DVJt3AjLEuHYL#key-1", "type":"Ed25519VerificationKey2018", "controller":"did:sov:6iHBriJn1DVJt3AjLEuHYL", "publicKeyBase58":"47ZPLULpKFGmeHLn8bbpVBzorKQwkgj1RA35Qu7h7bE5" } ], "authentication":[ "did:sov:6iHBriJn1DVJt3AjLEuHYL#key-1" ], "assertionMethod":[ "did:sov:6iHBriJn1DVJt3AjLEuHYL#key-1" ], "service":[ { "id":"did:sov:6iHBriJn1DVJt3AjLEuHYL#did-communication", "type":"did-communication", "serviceEndpoint":"https://bpa-acapy.int.eu.spherity.io", "recipientKeys":[ "did:sov:6iHBriJn1DVJt3AjLEuHYL#key-1" ], "routingKeys":[ ], "priority":1 }, { "id":"did:sov:6iHBriJn1DVJt3AjLEuHYL#profile", "type":"profile", "serviceEndpoint":"https://bpa.int.eu.spherity.io/profile.jsonld" } ] }
As you can see the DIDs are same so they are actually pointing to the same entity. However the content of the DIDDoc are different, and the most critical part of the difference is, in the service section, the universal resolver returns two more blocks, which does not contain property 'id'. And because of that, when I am trying to use this DIDDoc for creating a connection via endpoint '/didexchange/create-request', the aca-py cant parse the DIDDoc and will throw error (field 'id' is required).
Here I think there are some problems with DIDDoc formatting in universal resolver.
The text was updated successfully, but these errors were encountered: