From 733de595e3eb03395e96662feb39b4ae6bf896a2 Mon Sep 17 00:00:00 2001 From: Valerio Setti Date: Fri, 24 Feb 2023 11:54:07 +0100 Subject: [PATCH] psa_crypto_rsa: remove PK_WRITE_C in psa_rsa_export_key Signed-off-by: Valerio Setti --- library/psa_crypto_rsa.c | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/library/psa_crypto_rsa.c b/library/psa_crypto_rsa.c index 0db425f11..3ff589dc8 100644 --- a/library/psa_crypto_rsa.c +++ b/library/psa_crypto_rsa.c @@ -172,10 +172,6 @@ psa_status_t mbedtls_psa_rsa_export_key(psa_key_type_t type, size_t data_size, size_t *data_length) { -/* Currently this is always true due to the fact that build_info.h auto-enables - * MBEDTLS_PK_WRITE_C whenever both PSA and RSA_C are enabled. - * However we keep the guard here to emphasize this dependency explicitly. */ -#if defined(MBEDTLS_PK_WRITE_C) int ret; mbedtls_pk_context pk; uint8_t *pos = data + data_size; @@ -212,14 +208,6 @@ psa_status_t mbedtls_psa_rsa_export_key(psa_key_type_t type, *data_length = ret; return PSA_SUCCESS; -#else - (void) type; - (void) rsa; - (void) data; - (void) data_size; - (void) data_length; - return PSA_ERROR_NOT_SUPPORTED; -#endif /* MBEDTLS_PK_WRITE_C */ } psa_status_t mbedtls_psa_rsa_export_public_key(