-
Notifications
You must be signed in to change notification settings - Fork 516
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
Failing to deserialize DIDDocumentRoot error when using the Indicio mediator and 0.10.2 ACA-Py instance #2497
Comments
Can reproduce on the existing problematic connections by just calling Not sure if possible there was just something formatted bad supplied as the service endpoint in the error case? Something that is allowed in but blows up getting out? I tried a bunch of random things in there doing manual recieve-invitations but can't find something specific. Looks like this code here only catches
( |
To clarify, when you say switching mediators, do you mean that you're establishing a new connection through a different mediator? That seems to be the case based on @loneil 's comment but just to wanted to verify my understanding. What were the did documents received by ACA-Py during connection for both scenarios? |
If you want to dump the logs, I can also parse that out myself, if that's helpful! |
@dbluhm -- updated the description. We were not switching mediators for existing connections. @cvarjao had been running a script that used the Indicio Mediator and the connections were not usuable, with the error above. After changing the script to use the BC Gov mediator, things started to work again. Does that help at all? |
|
If someone knows what the bifold wallet app with indício mediator would be putting as the Service Endpoint (when receiving the invitation) that would be helpful I think. Or know how to check what that would be in an existing connection |
@cvarjao -- could you please rerun the failing test and get a log on your side, and after you run the test, indicate the time so that an ACA-Py instance log can be extracted for the time in question. |
I don't know if we should investigate this issue more. But it looks like nothing really works with Indicio mediator. I've tried BC Showcase, and Animo Demo, neither of them worked. I think Animo is AFJ-based, BC Showcase is aca-py/traction based. |
@dbluhm — can you respond to @cvarjao note? That seems very odd that the Indicio Mediator is not working. @cvarjao to confirm, what you did was:
@loneil is using the same connections that @cvarjao tried to establish to reproduce the error with @dbluhm — does that help? |
Would still appreciate more logs from these interactions but in the absence of more details and with evidence of things working well with other setups, we're probably okay to proceed with a release. |
Here is a log from the wallet side. |
This is the acapy log (keys have been redacted). |
DID Document received by ACA-Py in Connection Request: {
"@type": "https://didcomm.org/connections/1.0/request",
"@id": "36ebc380-c39a-4e46-bf49-029d6ca0053c",
"label": "My Wallet - 4985",
"connection": {
"DID": "SBV4Dq9TNMZ7ubdjAs3WHK",
"DIDDoc": {
"@context": "https://w3id.org/did/v1",
"publicKey": [
{
"id": "SBV4Dq9TNMZ7ubdjAs3WHK#1",
"controller": "SBV4Dq9TNMZ7ubdjAs3WHK",
"type": "Ed25519VerificationKey2018",
"publicKeyBase58": "Ej1mdRCVf5WBpkZSA7W6jgnY5tS2xe6KU6FyUnEQ2Abf"
}
],
"service": [
{
"id": "SBV4Dq9TNMZ7ubdjAs3WHK#IndyAgentService",
"serviceEndpoint": "didcomm:transport/queue",
"type": "IndyAgent",
"priority": 0,
"recipientKeys": [
"Ej1mdRCVf5WBpkZSA7W6jgnY5tS2xe6KU6FyUnEQ2Abf"
],
"routingKeys": []
}
],
"authentication": [
{
"publicKey": "SBV4Dq9TNMZ7ubdjAs3WHK#1",
"type": "Ed25519SignatureAuthentication2018"
}
],
"id": "SBV4Dq9TNMZ7ubdjAs3WHK"
}
},
"~thread": {
"thid": "36ebc380-c39a-4e46-bf49-029d6ca0053c",
"pthid": "434c562c-b483-4cc3-ba34-70fb733f0f9b"
},
"~transport": {
"return_route": "all"
}
} The serviceEndpoint is not consistent with one that has correctly established mediation. The On the wallet side, the wallet successfully completed a connection with the Indicio Public Mediator but on opening a WS connection and sending a mediation request, no response was received from the mediator. Unclear from the logs how long of a timeout this was after. I'm checking to see if we have any logs for the exchange on the mediator end. The Indicio Public Mediator is not running 0.10.2-rc0 though so any issues there are not a result of any recent changes to ACA-Py. |
Thanks @dbluhm — I’ll hold on the release. |
I've got the changes in for pydid: Indicio-tech/pydid#75 I'll get this out into a release shortly and then prepare a PR for ACA-Py. |
The error on |
@dbluhm — I see that there is a fix in the pydid library that you are proposing. Could you summarize what occured that triggered the issue, what the fix does, and what is needed in 0.10.2 specifically, and ACA-Py generally to resolve the issue? That would help me understand the issue. |
The trigger for this issue is that 0.10.1 normalized the handling of DIDs by always "resolving" the recipient DID on sending an outbound message. After resolution, the document is parsed using PyDID to extract DIDComm Service endpoint information. PyDID's Regardless of this fix, there still would have been issues in the scenario that brought the The change needed in 0.10.2 is to pull in the updated PyDID release (working on preparing this now). Hope that helps clear things up! |
Thanks! Awesome. So we get a double fix for this problem. We do some cleanup in pydid/ACA-Py, but also discovered a problem in Bifold, per “But it will be because there was no valid transport rather than because validation of the doc failed, which, in turn, was caused by the wallet never actually properly establishing mediation with the Indicio Mediator before connecting to our inviter ACA-Py instance.” @cvarjao — could you please have the Bifold community address this second issue? |
Relevant logs from wallet; when mediation establishment failed, it proceeded to configuration instead of stopping. I'm not sure this is really a misbehavior of bifold or not but I'll leave that up to the bifold developers. Meanwhile, I'll ping Kim about why it might have gotten this back from our mediator:
|
AFJ is the component handling mediator and things like that. I will see if we can reproduce in vanilla Node/AFJ environment. We have also found issues related to running on the device itself, as it actually doesn't use the NodeJS engine, but actually Hermes. |
This will correct the errror reported in openwallet-foundation#2497. Signed-off-by: Daniel Bluhm <[email protected]>
The issuer part was fixed in 0.10.3. The underlying issue requires a fix in AFJ. Closing. |
[Updated this description to clarify the issue...]
We were testing a deployment of 0.10.2, and were getting errors when connections were established using the Indicio Public Mediator. When we switched to use the BC Gov Mediator instance, things worked again.
This was observed using ACA-Py
0.10.2rc0
in a Traction multi-tenant instance, targeting a BC Wallet emulator - @cvarjao please add context if you have more information.c.c.: @loneil who has been looking into this, @dbluhm based on expressed interest from today's ACA-Pug meeting
The text was updated successfully, but these errors were encountered: