openssl/providers/implementations/keymgmt
afshinpir a3207163ef Updated rsa_has() for correct validation
CLA: trivial
In RSA, `(n,e)` and `(n,d)` identify public key and private key.
Modulus `n` is the common part. So I updated `rsa_has()` to validate
these pairs correctly. `OSSL_KEYMGMT_SELECT_KEYPAIR` is common part
for both public and private key, so I changed it to check `n` of
RSA and for `OSSL_KEYMGMT_SELECT_PUBLIC_KEY`, `e` is checked. Before
this change, if `selection` was `OSSL_KEYMGMT_SELECT_PRIVATE_KEY` and
only `e` and `d` was in the RSA structure, the function returns 1
while it was incorrect.

Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/20455)
2023-03-15 08:28:39 +11:00
..
build.info Drop libimplementations.a 2021-05-07 10:17:23 +02:00
dh_kmgmt.c Prevent creating DSA and DH keys without parameters through import 2023-02-07 17:05:10 +01:00
dsa_kmgmt.c Prevent creating DSA and DH keys without parameters through import 2023-02-07 17:05:10 +01:00
ec_kmgmt_imexport.inc Fix copyrights 2022-02-03 13:56:38 +01:00
ec_kmgmt.c Fix potential NULL pointer dereference 2023-01-17 17:37:55 +01:00
ecx_kmgmt.c Stop raising ERR_R_MALLOC_FAILURE in most places 2022-10-05 14:02:03 +02:00
kdf_legacy_kmgmt.c Update copyright year 2022-05-03 13:34:51 +01:00
mac_legacy_kmgmt.c Stop raising ERR_R_MALLOC_FAILURE in most places 2022-10-05 14:02:03 +02:00
rsa_kmgmt.c Updated rsa_has() for correct validation 2023-03-15 08:28:39 +11:00