psa: remove redundant GENPRIME when RSA_KEY_PAIR_GENERATE is defined
Signed-off-by: Valerio Setti <valerio.setti@nordicsemi.no>
This commit is contained in:
parent
0d5c5e5a38
commit
76df8c1900
2 changed files with 4 additions and 8 deletions
|
@ -7410,16 +7410,14 @@ psa_status_t psa_generate_key_internal(
|
|||
#endif /* MBEDTLS_PSA_BUILTIN_KEY_TYPE_DES */
|
||||
} else
|
||||
|
||||
#if defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_RSA_KEY_PAIR_GENERATE) && \
|
||||
defined(MBEDTLS_GENPRIME)
|
||||
#if defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_RSA_KEY_PAIR_GENERATE)
|
||||
if (type == PSA_KEY_TYPE_RSA_KEY_PAIR) {
|
||||
return mbedtls_psa_rsa_generate_key(attributes,
|
||||
key_buffer,
|
||||
key_buffer_size,
|
||||
key_buffer_length);
|
||||
} else
|
||||
#endif /* defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_RSA_KEY_PAIR_GENERATE)
|
||||
* defined(MBEDTLS_GENPRIME) */
|
||||
#endif /* defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_RSA_KEY_PAIR_GENERATE) */
|
||||
|
||||
#if defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_ECC_KEY_PAIR_GENERATE)
|
||||
if (PSA_KEY_TYPE_IS_ECC(type) && PSA_KEY_TYPE_IS_KEY_PAIR(type)) {
|
||||
|
|
|
@ -241,8 +241,7 @@ psa_status_t mbedtls_psa_rsa_export_public_key(
|
|||
#endif /* defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_RSA_KEY_PAIR_EXPORT) ||
|
||||
* defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_RSA_PUBLIC_KEY) */
|
||||
|
||||
#if defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_RSA_KEY_PAIR_GENERATE) && \
|
||||
defined(MBEDTLS_GENPRIME)
|
||||
#if defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_RSA_KEY_PAIR_GENERATE)
|
||||
static psa_status_t psa_rsa_read_exponent(const uint8_t *domain_parameters,
|
||||
size_t domain_parameters_size,
|
||||
int *exponent)
|
||||
|
@ -304,8 +303,7 @@ psa_status_t mbedtls_psa_rsa_generate_key(
|
|||
|
||||
return status;
|
||||
}
|
||||
#endif /* defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_RSA_KEY_PAIR_GENERATE)
|
||||
* defined(MBEDTLS_GENPRIME) */
|
||||
#endif /* defined(MBEDTLS_PSA_BUILTIN_KEY_TYPE_RSA_KEY_PAIR_GENERATE) */
|
||||
|
||||
/****************************************************************/
|
||||
/* Sign/verify hashes */
|
||||
|
|
Loading…
Reference in a new issue