mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-08-01 10:06:53 +03:00
Fix zeroization at NULL pointer
Signed-off-by: Dave Rodgman <dave.rodgman@arm.com>
This commit is contained in:
@ -5635,7 +5635,9 @@ static int tls_prf_generic( mbedtls_md_type_t md_type,
|
|||||||
exit:
|
exit:
|
||||||
mbedtls_md_free( &md_ctx );
|
mbedtls_md_free( &md_ctx );
|
||||||
|
|
||||||
|
if ( tmp != NULL )
|
||||||
mbedtls_platform_zeroize( tmp, tmp_len );
|
mbedtls_platform_zeroize( tmp, tmp_len );
|
||||||
|
|
||||||
mbedtls_platform_zeroize( h_i, sizeof( h_i ) );
|
mbedtls_platform_zeroize( h_i, sizeof( h_i ) );
|
||||||
|
|
||||||
mbedtls_free( tmp );
|
mbedtls_free( tmp );
|
||||||
|
Reference in New Issue
Block a user