You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
you'd expect it to eventually do something at least error, but it just hangs as do exponents 5 and 17, in fact the only one that seems to work is 0x10001.
This isn't a speed thing since I can generate a key like this in browser crypto and in pure javascript pretty easily.
looking at the tests it looks like 0x10001 is the only key being tested against
The text was updated successfully, but these errors were encountered:
if (EVP_PKEY_CTX_set_rsa_keygen_pubexp(ctx.get(), bn.get()) <= 0)
returnfalse;
}
has code specific to non-default exponents, which explains why this specific path can fault but not the default exponent.
The exponent seems to be changing to a 0x555558b35110 somewhere along the way, though it is correct at BN_set_word() in the above code. Still looking, in between doing other things.
EVP_PKEY_CTX_set_rsa_keygen_pubexp() accepts ownership of the exponent
on success, so do not free it.
Fixes: #27087Fixes: #29433
PR-URL: #27092
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Tobias Nießen <tniessen@tnie.de>
Reviewed-By: James M Snell <jasnell@gmail.com>
certain exponents cause crypto.generateKeyPair to hang
try running
you'd expect it to eventually do something at least error, but it just hangs as do exponents 5 and 17, in fact the only one that seems to work is 0x10001.
This isn't a speed thing since I can generate a key like this in browser crypto and in pure javascript pretty easily.
looking at the tests it looks like 0x10001 is the only key being tested against
The text was updated successfully, but these errors were encountered: