openwallet-foundation / acapy

Hyperledger Aries Cloud Agent Python (ACA-Py) is a foundation for building decentralized identity applications and services running in non-mobile environments.
https://wiki.hyperledger.org/display/aries
Apache License 2.0
412 stars 512 forks source link

problem report is sent when no exchange exists yet #1730

Closed TimoGlastra closed 1 year ago

TimoGlastra commented 2 years ago

When sending a credential offer in v1 and creating a bad request (in my case I made a type in one of the attribute names) ACA-Py will send a problem report to the other agent without having initiated the protocol.

Not sure if other endpoints / protocols are affected, but I find it an quite amusing issue :)

swcurran commented 2 years ago

That's funny... :-).

swcurran commented 2 years ago

While funny, we should prevent this -- having a protocol initiator reporting a problem to another agent before the protocol has started. It would be good to have someone look into this.

First, we need to look at this in this specific case -- issue credential protocol (v1 and presumably v2). How do we prevent a problem report from the initiator going out before the first message of the protocol has been sent?

Second, what other protocols are susceptible to this issue? Is there a cross-cutting mechanism that can be applied to handle this, or does each protocol have to be updated?

Ennovate-com commented 1 year ago

Reply to @swcurran Re: Second, what other protocols are susceptible to this issue? I see the issue in Credential Issue Exchange v1.0 (this issue) and v2.0 (Issue #2512). I don't see it in the Proof Exchange - there, instead of the report_problem call I see comments such as # other party does not care about our false protocol start.

@TimoGlastra This issue should be fixed by PR #2519. Can you please verify and close this issue if that is the case.