Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Update the default hash and curve selection for X.509 and TLS #4604
Update the default hash and curve selection for X.509 and TLS #4604
Changes from all commits
ffb92da
ae270bf
3758fd6
2c69fa2
12b5b38
5752e59
377c91e
b1940a7
a28f0f5
c5b9510
3beb72e
b26696b
799eee6
3b3aa36
4a02cef
55cb9af
6b1f64a
ec78bc4
a03fb29
3995750
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note that the X.509 and TLS profiles are currently aligned, but we don't promise that they will remain so forever.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpick: Here we state that the set is the same as for certificate verification. However, the above description includes SM3, whereas the certificate profile doesn't:
4e754c7#diff-2617ff9076cb3f3c76f4c4e86c40ed9dc2557905d0e2ec7a8a7844e845d88900R336
(I appreciate that SM3 is still in a PR and the TLS cipher suites are still in a draft stage.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We may or may not want change the documentation of
mbedtls_md_list
, which currently guarantees that the list “starts with the strongest available hashes” — which by the way means that the list has to be ordered from strongest to weakest, since disabling any subset must leave the strongest remaining hash at the top.Related: where to add SM3 in
mbedtls_md_list()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This excludes SHA-224. With 3-DES on its way out, I don't expect SHA-224 to gain in popularity.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since X.509 support in Mbed TLS is mainly intended for use with TLS and secp256k1 is deprecated in TLS, I decided to remove secp256k1 from the default X.509 profile. What tipped the balance for me is that this is the safe choice from a backward compatibility perspective: we wouldn't remove a curve in a minor version unless there were serious security concerns, but we can add a curve in a minor version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure if we should up this to 3072.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Well according to SSL pulse ("Key strength distribution"), 2048 is still the most frequent size so I don't think we can require more than that.