Merge remote-tracking branch 'origin/pr/2454' into development

This commit is contained in:
Jaeden Amero 2019-02-21 12:04:34 +00:00
commit 461bd3dcca
4 changed files with 6 additions and 6 deletions

View File

@ -1238,7 +1238,7 @@ int mbedtls_cipher_crypt( mbedtls_cipher_context_t *ctx,
(mbedtls_cipher_context_psa *) ctx->cipher_ctx; (mbedtls_cipher_context_psa *) ctx->cipher_ctx;
psa_status_t status; psa_status_t status;
psa_cipher_operation_t cipher_op; psa_cipher_operation_t cipher_op = PSA_CIPHER_OPERATION_INIT;
size_t part_len; size_t part_len;
if( ctx->operation == MBEDTLS_DECRYPT ) if( ctx->operation == MBEDTLS_DECRYPT )

View File

@ -6572,7 +6572,7 @@ static void ssl_calc_finished_tls_sha256(
unsigned char padbuf[32]; unsigned char padbuf[32];
#if defined(MBEDTLS_USE_PSA_CRYPTO) #if defined(MBEDTLS_USE_PSA_CRYPTO)
size_t hash_size; size_t hash_size;
psa_hash_operation_t sha256_psa; psa_hash_operation_t sha256_psa = PSA_HASH_OPERATION_INIT;
psa_status_t status; psa_status_t status;
#else #else
mbedtls_sha256_context sha256; mbedtls_sha256_context sha256;
@ -6648,7 +6648,7 @@ static void ssl_calc_finished_tls_sha384(
unsigned char padbuf[48]; unsigned char padbuf[48];
#if defined(MBEDTLS_USE_PSA_CRYPTO) #if defined(MBEDTLS_USE_PSA_CRYPTO)
size_t hash_size; size_t hash_size;
psa_hash_operation_t sha384_psa; psa_hash_operation_t sha384_psa = PSA_HASH_OPERATION_INIT;
psa_status_t status; psa_status_t status;
#else #else
mbedtls_sha512_context sha512; mbedtls_sha512_context sha512;
@ -10246,7 +10246,7 @@ int mbedtls_ssl_get_key_exchange_md_tls1_2( mbedtls_ssl_context *ssl,
mbedtls_md_type_t md_alg ) mbedtls_md_type_t md_alg )
{ {
psa_status_t status; psa_status_t status;
psa_hash_operation_t hash_operation; psa_hash_operation_t hash_operation = PSA_HASH_OPERATION_INIT;
psa_algorithm_t hash_alg = mbedtls_psa_translate_md( md_alg ); psa_algorithm_t hash_alg = mbedtls_psa_translate_md( md_alg );
MBEDTLS_SSL_DEBUG_MSG( 1, ( "Perform PSA-based computation of digest of ServerKeyExchange" ) ); MBEDTLS_SSL_DEBUG_MSG( 1, ( "Perform PSA-based computation of digest of ServerKeyExchange" ) );

View File

@ -1929,7 +1929,7 @@ static int x509_crt_check_signature( const mbedtls_x509_crt *child,
if( mbedtls_md( md_info, child->tbs.p, child->tbs.len, hash ) != 0 ) if( mbedtls_md( md_info, child->tbs.p, child->tbs.len, hash ) != 0 )
return( -1 ); return( -1 );
#else #else
psa_hash_operation_t hash_operation; psa_hash_operation_t hash_operation = PSA_HASH_OPERATION_INIT;
psa_algorithm_t hash_alg = mbedtls_psa_translate_md( child->sig_md ); psa_algorithm_t hash_alg = mbedtls_psa_translate_md( child->sig_md );
if( psa_hash_setup( &hash_operation, hash_alg ) != PSA_SUCCESS ) if( psa_hash_setup( &hash_operation, hash_alg ) != PSA_SUCCESS )

View File

@ -142,7 +142,7 @@ int mbedtls_x509write_csr_der( mbedtls_x509write_csr *ctx, unsigned char *buf, s
size_t len = 0; size_t len = 0;
mbedtls_pk_type_t pk_alg; mbedtls_pk_type_t pk_alg;
#if defined(MBEDTLS_USE_PSA_CRYPTO) #if defined(MBEDTLS_USE_PSA_CRYPTO)
psa_hash_operation_t hash_operation; psa_hash_operation_t hash_operation = PSA_HASH_OPERATION_INIT;
size_t hash_len; size_t hash_len;
psa_algorithm_t hash_alg = mbedtls_psa_translate_md( ctx->md_alg ); psa_algorithm_t hash_alg = mbedtls_psa_translate_md( ctx->md_alg );
#endif /* MBEDTLS_USE_PSA_CRYPTO */ #endif /* MBEDTLS_USE_PSA_CRYPTO */