Rename hash max sizes for consistency

Use "hash" throughout the library, not "md" as in Mbed TLS.
This commit is contained in:
Gilles Peskine 2018-06-18 22:16:43 +02:00 committed by itayzafrir
parent dec7261df1
commit b3e6e5deeb
3 changed files with 7 additions and 39 deletions

View file

@ -46,11 +46,11 @@
#include "mbedtls/sha512.h"
#if defined(MBEDTLS_SHA512_C)
#define PSA_CRYPTO_MD_MAX_SIZE 64
#define PSA_CRYPTO_MD_BLOCK_SIZE 128
#define PSA_HASH_MAX_SIZE 64
#define PSA_HMAC_MAX_HASH_BLOCK_SIZE 128
#else
#define PSA_CRYPTO_MD_MAX_SIZE 32
#define PSA_CRYPTO_MD_BLOCK_SIZE 64
#define PSA_HASH_MAX_SIZE 32
#define PSA_HMAC_MAX_HASH_BLOCK_SIZE 64
#endif
struct psa_hash_operation_s
@ -89,7 +89,7 @@ typedef struct
/** The hash context. */
struct psa_hash_operation_s hash_ctx;
/** The HMAC part of the context. */
uint8_t opad[PSA_CRYPTO_MD_BLOCK_SIZE];
uint8_t opad[PSA_HMAC_MAX_HASH_BLOCK_SIZE];
} psa_hmac_internal_data;