-
Notifications
You must be signed in to change notification settings - Fork 18k
crypto/rsa: 4096 bit keys are not generated with BoringCrypto #58803
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
Comments
@gopherbot please open a Go 1.20 backport issue for this. Go 1.20 updated the BoringCrypto module and started using BoringCrypto for RSA 4096 bit keys in crypto/x509, but not in GenerateKey. The two are not necessarily correlated (most X.509 keys are loaded from disk, not generated) but using unverified crypto unexpectedly is not great, and the fix is simple. /cc @rsc @golang/security |
Backport issue(s) opened: #58927 (for 1.20). Remember to create the cherry-pick CL(s) as soon as the patch is submitted to master, according to https://go.dev/wiki/MinorReleases. |
Change https://go.dev/cl/474515 mentions this issue: |
Change https://go.dev/cl/495735 mentions this issue: |
Updates #58803 Fixes #58927 Change-Id: I097938ff61dae2b65214f8d0126d68de63525f5b Reviewed-on: https://go-review.googlesource.com/c/go/+/474515 Run-TryBot: Filippo Valsorda <filippo@golang.org> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Dmitri Shuralyov <dmitshur@google.com> Reviewed-by: Roland Shoemaker <roland@golang.org> (cherry picked from commit 7bc3281) Reviewed-on: https://go-review.googlesource.com/c/go/+/495735 Reviewed-by: Heschi Kreinick <heschi@google.com>
Updates golang#58803 Fixes golang#58927 Change-Id: I097938ff61dae2b65214f8d0126d68de63525f5b Reviewed-on: https://go-review.googlesource.com/c/go/+/474515 Run-TryBot: Filippo Valsorda <filippo@golang.org> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Dmitri Shuralyov <dmitshur@google.com> Reviewed-by: Roland Shoemaker <roland@golang.org> (cherry picked from commit 7bc3281) Reviewed-on: https://go-review.googlesource.com/c/go/+/495735 Reviewed-by: Heschi Kreinick <heschi@google.com>
Updates golang#58803 Fixes golang#58927 Change-Id: I097938ff61dae2b65214f8d0126d68de63525f5b Reviewed-on: https://go-review.googlesource.com/c/go/+/474515 Run-TryBot: Filippo Valsorda <filippo@golang.org> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Dmitri Shuralyov <dmitshur@google.com> Reviewed-by: Roland Shoemaker <roland@golang.org> (cherry picked from commit 7bc3281) Reviewed-on: https://go-review.googlesource.com/c/go/+/495735 Reviewed-by: Heschi Kreinick <heschi@google.com>
https://go.dev/cl/423362 updated the BoringCrypto module to one that supports RSA 4096 bit keys, and #41147 removed the limitation in crypto/x509, but crypto/rsa still has a check that only uses BoringCrypto for 2048 and 3078 bit keys, so 4096 bit keys are generated with the pure Go implementation.
/cc @golang/security @rsc
The text was updated successfully, but these errors were encountered: