Skip to content
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

Removal of OOB and DID Exchange information #73

Merged

Conversation

TelegramSam
Copy link
Collaborator

Given the move to zero round trip models, these items are not longer needed.
Signed-off-by: Sam Curren [email protected]

These items are not longer neededSigned-off-by: Sam Curren <[email protected]>
@tplooker
Copy link
Member

tplooker commented Jul 2, 2020

LGTM, will await others review before deciding to merge

@TelegramSam TelegramSam added the not yet ready This is not yet ready to be completed label Jul 6, 2020



#### OutOfBand Protocol

Invitations are usually the first message passed between parties. They are passed out of band, such as in a QR code or a link that can either open in an app or in a browser containing getting started instructions.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are the concepts in OOB invitations being moved elsewhere in the spec?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sort of. The ability to pass a message as an attachment isn't needed under the proposed 0RTT model.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The OutOfBand protocol provides a common mechanism to correlate a "not DIDComm activity" to a DIDComm message. This concept isn't about 0RTT vs DID Exchange but rather about defining a common mechanism for this capability.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Scenario: Alice has received an “invitation” (not in a DIDComm message) from Bob which then triggers Alice to send a DIDComm message to Bob.

OutOfBand defines an invitation format, goal/goal code, versioning information, and enables correlation based on the invitation message ID to a subsequent DIDComm message thread.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

By (not in a DIDComm message) I think you mean "Not in a DIDComm Encrypted message", but still in one of the standard formats in the spec? (example: URL/QR code, or another yet to be defined format?)

Invitation format: See the QR code PR for defined format. #74
Versioning Information: Only pertained to the handshake protocols, which are not needed given the presence of the from and from_prior headers.
Correlation based on message ID: Correlate with the message ID of the message sent.

Goal/Goal Code: There isn't currently a replacement for this, or actually for the 'I want to exchange DIDs for no declared reason'. I believe the answer to this is deeper and related to the discussion about the ux of a user accepting an invitation. I'm going to open an issue to discuss this particular topic.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we've lost a cheap and sensible way to create an OOB invitation with explicit didcomm parameters (eg. no public DID).... see my comments here: #33 (comment)

@@ -2,254 +2,7 @@

A Connection is the practical application of a relationship in DID Communication. Having a connection means that each party in the relationship has a DID for the other parties, and parties can communicate securely using the keys and endpoints within each DID Document.

In order to establish a new connection, we use the OutOfBand Protocol and the DID Exchange Protocol.
In order to establish a new connection, Simply exchange a new message between parties. Knowing the DID of the other parties does not indicate any level of trust. Using the connection to establish a foundation of trust is the next step.
Copy link
Contributor

@troyronda troyronda Jul 6, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In order to establish a new connection

At what point is the connection considered established by each party? Is it when the party receives a message back from the other party? (does the act of sending a message to a new DID constitute a pending connection until a message is returned?)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a great question. I've been spending some time considering our mental models around connections. More on this to come.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

More thoughts on this, after discussion in both the Aries WG call and the DIDComm WG call today.

The historical context of 'established' is very binary: a connection is either 'established' or it isn't. I believe the right answer is closer to this: When you receive a message from the other party, you know their information about how to contact you is accurate. When they reply to something you sent, you know your information about how to contact them is accurate.


##### 1. Exchange Request

The exchange request message is used to communicate the DID document of the _invitee_ to the _inviter_ using the provisional service information present in the _invitation_ message.
Copy link
Contributor

@troyronda troyronda Jul 6, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume this particular purpose of the DID Exchange Protocol is obsoleted by usage of initial-state.

I am wondering about the nuance of peer DIDs and initial-state after the connection is considered established. Should initial-state continue to be sent after that point?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think yes, though I think initial-state might not be the right term for that.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the parties have an implicit connection establishment model (on top of the 0RTT any message model), then perhaps they could choose to stop sending initial-state once established. Without knowledge that the other party has persisted then, yes, I guess they would have to include with every message.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree. How the further changes to a did:peer did are communicated to the various parties is something that the method will need to define. Perhaps deltas a communicated in a query param as well, and dropped upon confirmation of receipt.

{
"@id": "5678876542345",
"@type": "https://didcomm.org/didexchange/2.0/request",
"~thread": { "pthid": "<id of invitation>" },
Copy link
Contributor

@troyronda troyronda Jul 6, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The correlation to invitations is a useful concept. I am generally curious how the invitation concept is moving around. (also above comment: https://github.com/decentralized-identity/didcomm-messaging/pull/73/files#r450510409)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

answered in above comment. tldr; You can still correlate to the message ID that is passed.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@TelegramSam can you point to the verbiage that describes the field used to indicate the thread's ID?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's not in the DIDComm JWM Profile

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Submitted PR #102 to add threading

@llorllale
Copy link
Contributor

I would first like to see the alternative in detail before actually removing this content.

@@ -2,254 +2,7 @@

A Connection is the practical application of a relationship in DID Communication. Having a connection means that each party in the relationship has a DID for the other parties, and parties can communicate securely using the keys and endpoints within each DID Document.

In order to establish a new connection, we use the OutOfBand Protocol and the DID Exchange Protocol.
In order to establish a new connection, Simply exchange a new message between parties. Knowing the DID of the other parties does not indicate any level of trust. Using the connection to establish a foundation of trust is the next step.
Copy link
Contributor

@troyronda troyronda Jul 7, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am also curious about scenarios where a sender wants an established connection prior to some action/message/protocol. In some cases, they may wish to confirm that the recipient is able to decrypt their messages; that the route is working; and that the recipient can respond with authenticated messages; (and authenticate the DID). For example, during issuance or (generally) authentication scenarios.

In essence, I am curious if there are any generic aspects of a more established connection that end up in the spec vs being left up to higher layer messages/protocols.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that decision is up to us - which components are so core that they need to be in the spec, and which are better left to higher layers? I consider this to be very unresolved as yet.


The _inviter_ will then craft an exchange response using the newly updated or provisioned information.

###### Request Errors
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am curious about the difference in errors originating from OOB/DID Exchange vs the DIDComm v2 model?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you pick an example to discuss?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I were to generalize the thought: How do we differentiate between a protocol-layer errors vs lower-layer concerns that were previously in these pre-step connection protocols. As an example, an unsupported DID method happened to be used (or unsupported key type or unsupported endpoint, etc).

Of course there is also possibilities such as unsupported protocols (or versions), but these would be cases that could happen regardless.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't believe OOB has anything in the spec about any of the errors you mentioned. Those are certainly important to think about, but I don't think there is a difference there between OOB/DIDExchange and 0RTT.

@woiue
Copy link

woiue commented Aug 4, 2020

@TelegramSam on the last didcomm wg call, people agreed to put OOB in its own section. People were also more in favour of naming _dc _oob. In terms of naming, while for us it is quite obvious we should also define what _dc or _oob stands for.

@TelegramSam
Copy link
Collaborator Author

Updated all those items in the other PR.

@TelegramSam TelegramSam removed the not yet ready This is not yet ready to be completed label Aug 10, 2020
* The [`~thread`](../../concepts/0008-message-id-and-threading/README.md#thread-object) decorator MUST be included:
* It MUST include the ID of the parent thread (`pthid`) such that the `request` can be correlated to the corresponding `invitation`. More on correlation [below](#correlating-requests-to-invitations).
* It MAY include the `thid` property. In doing so, implementations MUST set its value to that of `@id` on the same request message. In other words, the values of `@id` and `~thread.thid` MUST be equal.
* The `label` attribute provides a suggested label for the DID being exchanged. This allows the user to tell multiple exchange requests apart. This is not a trusted attribute.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We're losing the label feature... what's the replacement?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems that was missing from the OOB PR when it was approved. I think the best replacement of the label in an OOB invitation would be in the form of a PR to out_of_band.md.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Discussed on today's call: we need to push in a PR to the OOB text to add the label

@dhh1128
Copy link
Contributor

dhh1128 commented Aug 28, 2020

+1 to merge from me

@troyronda
Copy link
Contributor

For those that want to validate a connection is established prior to another action, we will still need a protocol to do so.

Related: #81

@troyronda
Copy link
Contributor

Regarding the usage of a ping protocol to enable an explicit RT at connection establishment.

In addition to using an authenticated RT ping, the other aspect is to enable linking that ping to an OOB request (e.g., stating the parent thread). This enables the Party to (A) know to respond to the ping; and (B) tie together the authenticated messages to an initial OOB action.

@llorllale
Copy link
Contributor

Regarding the usage of a ping protocol to enable an explicit RT at connection establishment.

In addition to using an authenticated RT ping, the other aspect is to enable linking that ping to an OOB request (e.g., stating the parent thread). This enables the Party to (A) know to respond to the ping; and (B) tie together the authenticated messages to an initial OOB action.

See #95


* The `@type` attribute is a required string value that denotes that the received message is an exchange request.
* The [`~thread`](../../concepts/0008-message-id-and-threading/README.md#thread-object) decorator MUST be included:
* It MUST include the ID of the parent thread (`pthid`) such that the `request` can be correlated to the corresponding `invitation`. More on correlation [below](#correlating-requests-to-invitations).
Copy link
Contributor

@troyronda troyronda Sep 14, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

parent thread will need to be defined elsewhere in the spec.

#95 (comment)

@tplooker tplooker merged commit ce54c00 into decentralized-identity:master Sep 21, 2020
@TelegramSam TelegramSam deleted the remove_connections branch September 28, 2020 17:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants