1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-07-29 11:41:15 +03:00

fix various issues

Signed-off-by: Jerry Yu <jerry.h.yu@arm.com>
This commit is contained in:
Jerry Yu
2021-10-08 15:14:45 +08:00
parent d96a5c2d86
commit c1ddeef53a
4 changed files with 14 additions and 21 deletions

View File

@ -7062,20 +7062,22 @@ int mbedtls_ssl_get_handshake_transcript( mbedtls_ssl_context *ssl,
size_t dst_len,
size_t *olen )
{
switch( md )
{
#if defined(MBEDTLS_SHA384_C)
if( md == MBEDTLS_MD_SHA384 )
{
case MBEDTLS_MD_SHA384:
return( ssl_get_handshake_transcript_sha384( ssl, dst, dst_len, olen ) );
}
else
#endif /* MBEDTLS_SHA512_C */
#endif /* MBEDTLS_SHA384_C */
#if defined(MBEDTLS_SHA256_C)
if( md == MBEDTLS_MD_SHA256 )
{
case MBEDTLS_MD_SHA256:
return( ssl_get_handshake_transcript_sha256( ssl, dst, dst_len, olen ) );
}
else
#endif /* MBEDTLS_SHA256_C */
default:
break;
}
return( MBEDTLS_ERR_SSL_INTERNAL_ERROR );
}
#endif /* !MBEDTLS_USE_PSA_CRYPTO */