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

Protocol negotiation #1

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Protocol negotiation #1

wants to merge 1 commit into from

Conversation

dennwc
Copy link
Contributor

@dennwc dennwc commented Feb 23, 2019

See the proposal text for more details.


This change is Reviewable

@dennwc dennwc self-assigned this Feb 23, 2019
@aler9
Copy link

aler9 commented Feb 26, 2019

Hello,

One of the possible reasons for hubs to continue using NMDC may be the fact that protocol
handshakes are incompatible, and it was not possible for a hub to upgrade the protocol
without breaking existing users.

I agree with that. ADC should have been conceived with a backward-compatible negotiation, a feature that, for instance, the new TLS 1.3 has with respect to older TLS versions. Given the situation, clients should have made the protocol choice mandatory (i.e. forcing the user to specify nmdc:// or adc://).

implement DC protocol negotiation at the TLS level by using ALPN

Straightforward, backward-compatible and easily implementable. I totally agree.
Everything you proposed regarding ALPN integrates well with both protocols.

Detecting the DC protocol for incoming connections

Regarding plain, unencrypted incoming connections, your proposal does not add any new feature to the protocol, but just describes a method to detect the protocol, that is also implemented in some libraries. It is not protocol-related.

HTTPS support for pingers

This could be done, efficacy depends on how many hubs will implement it.

PS: i suggest to submit the ALPN proposal to the DC foundation ( https://www.dcbase.org/ ), since they maintain the most complete and up-to-date documentation regarding ADC.

@dennwc
Copy link
Contributor Author

dennwc commented Feb 26, 2019

Thanks for the feedback!

Regarding plain, unencrypted incoming connections, your proposal does not add any new feature to the protocol, but just describes a method to detect the protocol, that is also implemented in some libraries. It is not protocol-related.

You are totally right, the only intention of this section is to describe how hubs can upgrade to TLS without breaking existing NMDC clients that use an unencrypted connection.

i suggest to submit the ALPN proposal to the DC foundation

The proposal is already submitted to DCNF and was discussed in the last meeting.

There is still few missing parts here, specifically the client identification in mixed mode (NMDC hub, ADC client-client connections).

@dennwc dennwc marked this pull request as ready for review April 11, 2019 23:24
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.

2 participants