Merge remote-tracking branch 'public/pr/1899' into mbedtls-2.7

This commit is contained in:
Simon Butcher 2018-09-26 22:00:02 +01:00
commit 9863afc5e2
2 changed files with 7 additions and 4 deletions

View file

@ -1,5 +1,11 @@
mbed TLS ChangeLog (Sorted per branch, date) mbed TLS ChangeLog (Sorted per branch, date)
= mbed TLS x.x.x branch released xxxx-xx-xx
Bugfix
* Fix failure in hmac_drbg in the benchmark sample application, when
MBEDTLS_THREADING_C is defined. Found by TrinityTonic, #1095
= mbed TLS 2.7.6 branch released 2018-08-31 = mbed TLS 2.7.6 branch released 2018-08-31
Security Security

View file

@ -594,7 +594,6 @@ int main( int argc, char *argv[] )
TIME_AND_TSC( "HMAC_DRBG SHA-1 (NOPR)", TIME_AND_TSC( "HMAC_DRBG SHA-1 (NOPR)",
if( mbedtls_hmac_drbg_random( &hmac_drbg, buf, BUFSIZE ) != 0 ) if( mbedtls_hmac_drbg_random( &hmac_drbg, buf, BUFSIZE ) != 0 )
mbedtls_exit(1) ); mbedtls_exit(1) );
mbedtls_hmac_drbg_free( &hmac_drbg );
if( mbedtls_hmac_drbg_seed( &hmac_drbg, md_info, myrand, NULL, NULL, 0 ) != 0 ) if( mbedtls_hmac_drbg_seed( &hmac_drbg, md_info, myrand, NULL, NULL, 0 ) != 0 )
mbedtls_exit(1); mbedtls_exit(1);
@ -603,7 +602,6 @@ int main( int argc, char *argv[] )
TIME_AND_TSC( "HMAC_DRBG SHA-1 (PR)", TIME_AND_TSC( "HMAC_DRBG SHA-1 (PR)",
if( mbedtls_hmac_drbg_random( &hmac_drbg, buf, BUFSIZE ) != 0 ) if( mbedtls_hmac_drbg_random( &hmac_drbg, buf, BUFSIZE ) != 0 )
mbedtls_exit(1) ); mbedtls_exit(1) );
mbedtls_hmac_drbg_free( &hmac_drbg );
#endif #endif
#if defined(MBEDTLS_SHA256_C) #if defined(MBEDTLS_SHA256_C)
@ -615,7 +613,6 @@ int main( int argc, char *argv[] )
TIME_AND_TSC( "HMAC_DRBG SHA-256 (NOPR)", TIME_AND_TSC( "HMAC_DRBG SHA-256 (NOPR)",
if( mbedtls_hmac_drbg_random( &hmac_drbg, buf, BUFSIZE ) != 0 ) if( mbedtls_hmac_drbg_random( &hmac_drbg, buf, BUFSIZE ) != 0 )
mbedtls_exit(1) ); mbedtls_exit(1) );
mbedtls_hmac_drbg_free( &hmac_drbg );
if( mbedtls_hmac_drbg_seed( &hmac_drbg, md_info, myrand, NULL, NULL, 0 ) != 0 ) if( mbedtls_hmac_drbg_seed( &hmac_drbg, md_info, myrand, NULL, NULL, 0 ) != 0 )
mbedtls_exit(1); mbedtls_exit(1);
@ -624,8 +621,8 @@ int main( int argc, char *argv[] )
TIME_AND_TSC( "HMAC_DRBG SHA-256 (PR)", TIME_AND_TSC( "HMAC_DRBG SHA-256 (PR)",
if( mbedtls_hmac_drbg_random( &hmac_drbg, buf, BUFSIZE ) != 0 ) if( mbedtls_hmac_drbg_random( &hmac_drbg, buf, BUFSIZE ) != 0 )
mbedtls_exit(1) ); mbedtls_exit(1) );
mbedtls_hmac_drbg_free( &hmac_drbg );
#endif #endif
mbedtls_hmac_drbg_free( &hmac_drbg );
} }
#endif #endif