aw
aw copied to clipboard
Negotiate aw and protocol versions during the handshake
Right now, peers engage in a simple handshake immediately after establishing a connection to verify their identities. This issue proposes extending the handshake to negotiate the aw
version being used, and the application-specific protocols being sent via aw
.
Negotiate aw
version
After establishing identities, the client is expected to send their aw
version to the server. This establishes whether or not the client and server are compatibility based on the aw
version. If the version is accepted by the server, then an acknowledgement must be sent back. Otherwise, the highest version supported by the server must be sent back, and the client must send an acknowledgement or drop the connection. Semver must be used to determine compatibility.
- [ ] Implemented
- [ ] Tested
- [ ] Documented
Negotiate protocol versions
If the aw
versions are compatible, then the client should send a list of the "application-level" protocols that it will be communicating via aw
. For example: in RenVM, the client might send the protocols hy-1.4.0
and zo-1.0.3
to establish the application-specific messages that can appear within the aw
messages. If all protocol version are accepted by the server, then an acknowledgement must be sent back. Otherwise, the highest version supported by the server for each protocol must be sent back, and the client must send an acknowledgement or drop the connection. Semver must be used to determine compatibility, but it is not required.
- [ ] Protocol versions standardised
- [ ] Implemented
- [ ] Tested
- [ ] Documented