Reach WebSocket + ProtoBuf based protocol, version 0

  • Initialisation messages Init and InitAuthenticatedSession both communicate the desired protocol version for the respective session
    • Init is a request for all the information necessary to receive and send messages
    • InitAuthenticatedSession indicates desire to establish a session allowing for operations specific to reachable peers and attestants.
  • All responses, including generic Ok/Error ones are represented by the wire::Response enum
    • Ok can be assumed to be the default response type when no other response type is specified below
    • Unsupported is the response if the node does not support the requested protocol version during initialisation
    • Decode Error is the response if any supplied data could not be successfully decoded, including Protocol Buffer Message conversion errors
    • Verification Error may be a response to requests with signatures of which the verification failed
    • Not Found may be a reply to requests involving IDs that do not identify any information currently stored on the node. All IDed requests are marked as such in the table below
requestuser roleresponseIDeddescription
wire::Initreach::ReachEnvelopeIdHint hint polls, pre-MessageVault upload
wire::InitAuthenticatedSessionreach::AuthenticationChallengerequest an authenticated session
envelope::EnvelopeIdenvelope::EnvelopeYesdownload Envelope
message_vault::MessageVaultIdmessage_vault::MessageVaultYesdownload MessageVault
message_vault::AddMessageVaultmessage_vault::SealedMessageVaultIdadd/upload MessageVault
envelope::EnvelopeSeedenvelope::SealedEnvelopeIdadd/upload Envelope
envelope::RemoveEnvelopeIdHintYesremove EnvelopeIdHint by Envelope.id and removal token
reach::AuthenticationAssuranceReachable, Attestantproof of signing ability for authenticated session
wire::ListEnvelopeIdsReachableenvelope::EnvelopeIdslists all EnvelopeIds currently stored on this node
reach::ReachablePublicKeyRingReachableadd ReachablePublicKeys for a reachable peer
reach::RemoveReachablePublicKeysReachableYesremove ReachablePublicKeys for a reachable peer
hint::AddSharedPublicKeysAttestantTODO
reach::AddReachableVerifyingKeysAttestantadd/onboard new ReachableVerifyingKeys
reach::RemoveReachableVerifyingKeysAttestantYesremove/offboard ReachableVerifyingKeys

Protocol processing state change

State changes indicated by "→". If no state changes are indicated, as well as in case of failures (Unsupported, Verification Error etc.) state remains unchanged after processing the request.

  • Init:
    • reach::Init → Ready
    • reach::InitAuthenticatedSession → Pending Authentication
  • Ready:
    • envelope::EnvelopeId
    • message_vault::MessageVault → Pending Envelope Upload
    • envelope::RemoveEnvelopeIdHint
  • Pending Envelope Upload
    • message::AddEnvelope
  • Pending Authentication:
    • reach::AuthenticationAssurance → Authenticated (Attestant) | Authenticated (Reachable) | Ready (Error)
  • Authenticated (Attestant):
    • hint::AddSharedPublicKeys
    • reach::AddVerifyingKeys
    • reach::RemoveVerifyingKeys
  • Authenticated (Reachable):
    • wire::Request::ListEnvelopeIds
    • reach::AddReachablePublicKeys
    • reach::RemoveReachablePublicKeys