diff options
Diffstat (limited to 'src/lib/libcrypto/rsa/rsa_pmeth.c')
-rw-r--r-- | src/lib/libcrypto/rsa/rsa_pmeth.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libcrypto/rsa/rsa_pmeth.c b/src/lib/libcrypto/rsa/rsa_pmeth.c index 1d51e52fe2..1b6d1de35d 100644 --- a/src/lib/libcrypto/rsa/rsa_pmeth.c +++ b/src/lib/libcrypto/rsa/rsa_pmeth.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: rsa_pmeth.c,v 1.29 2019/10/31 13:06:30 jsing Exp $ */ | 1 | /* $OpenBSD: rsa_pmeth.c,v 1.30 2019/10/31 13:10:40 jsing Exp $ */ |
2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 2 | /* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
3 | * project 2006. | 3 | * project 2006. |
4 | */ | 4 | */ |
@@ -454,8 +454,8 @@ pkey_rsa_ctrl(EVP_PKEY_CTX *ctx, int type, int p1, void *p2) | |||
454 | return 1; | 454 | return 1; |
455 | 455 | ||
456 | case EVP_PKEY_CTRL_RSA_KEYGEN_BITS: | 456 | case EVP_PKEY_CTRL_RSA_KEYGEN_BITS: |
457 | if (p1 < 256) { | 457 | if (p1 < RSA_MIN_MODULUS_BITS) { |
458 | RSAerror(RSA_R_INVALID_KEYBITS); | 458 | RSAerror(RSA_R_KEY_SIZE_TOO_SMALL); |
459 | return -2; | 459 | return -2; |
460 | } | 460 | } |
461 | rctx->nbits = p1; | 461 | rctx->nbits = p1; |