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

Decide servers should have accounted for this already #6

Merged
merged 1 commit into from
Mar 18, 2024

Conversation

davidben
Copy link
Collaborator

@davidben davidben commented Mar 14, 2024

This cuts the document by about half.

In the original version of this document, I assumed that attacker control over the key_share list was a novel scenario that servers were not expected to previously account for. After all, we went through quite a lot of trouble to capture both ClientHellos in the handshake transcript.

On reflection after MT filed issue #5, I think that was too timid of a position. Although rfc8446bis improves the wording, RFC 8446 already was quite clear that the key_share list may be an arbitrary subset of the supported_groups list and doesn't reflect the full preferences. So we can reasonably claim that any key_share-first server either:

  • has considered this and believes the groups are comparable in preference, or

  • did not understand the protocol and failed to implement their desired policy correctly.

The first is a perfectly valid choice. It's not a good choice between ECDH and post-quantum, but it's perfectly defensible between post-quantum options or between two ECDH curves. The second is a server bug and the server's responsibility to fix, even if it is exacerbated by new client behavior.

If we believe that, there is nothing wrong with a client predicting key_share based on any heuristic, be it DNS, random probes to avoid compat risks of large ClientHellos, whatever you negotiated previously, the phase of the moon, racing two connections, or a popularity contest. So now all the stuff around prediction-safe vs prediction-unsafe groups is cut, and we just include a discussion in Security Considerations that this was okay.

This cuts the document by about half.

In the original version of this document, I assumed that attacker
control over the key_share list was a novel scenario that servers were
not expected to previously account for. After all, we went through quite
a lot of trouble to capture both ClientHellos in the handshake
transcript.

On reflection after MT filed issue #5, I think that was too timid of a
position. Although rfc8446bis improves the wording, RFC 8446 *already*
was quite clear that the key_share list may be an arbitrary subset of
the supported_groups list and doesn't reflect the full preferences. So
we can reasonably claim that any key_share-first server either:

* has considered this and believes the groups are compariable in
  preference, or

* did not understand the protocol and failed to implement their desired
  policy correctly.

The first is a perfectly valid choice. It's not a good choice between
ECDH and post-quantum, but it's perfectly defensible between
post-quantum options or between two ECDH curves. The second is a server
bug and the server's responsibility to fix, even if it is exacerbated by
new client behavior.
@davidben
Copy link
Collaborator Author

@martinthomson and @ekr, curious how you feel about this.

@davidben
Copy link
Collaborator Author

Since PR guts the whole document, this link is probably easier to read than the diff:
https://davidben.github.io/tls-key-share-prediction/just-decide-its-okay/draft-davidben-tls-key-share-prediction.html

@davidben davidben merged commit d3852e8 into main Mar 18, 2024
2 checks passed
@davidben davidben deleted the just-decide-its-okay branch March 18, 2024 02:52
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.

None yet

1 participant