mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-26 17:45:44 +01:00
Merge remote-tracking branch 'upstream-public/pr/1547' into development-proposed
This commit is contained in:
commit
73db8380ca
@ -72,6 +72,9 @@ Changes
|
|||||||
* In the SSL module, when f_send, f_recv or f_recv_timeout report
|
* In the SSL module, when f_send, f_recv or f_recv_timeout report
|
||||||
transmitting more than the required length, return an error. Raised by
|
transmitting more than the required length, return an error. Raised by
|
||||||
Sam O'Connor in #1245.
|
Sam O'Connor in #1245.
|
||||||
|
* Improve robustness of mbedtls_ssl_derive_keys against the use of
|
||||||
|
HMAC functions with non-HMAC ciphersuites. Independently contributed
|
||||||
|
by Jiayuan Chen in #1377. Fixes #1437.
|
||||||
|
|
||||||
= mbed TLS 2.8.0 branch released 2018-03-16
|
= mbed TLS 2.8.0 branch released 2018-03-16
|
||||||
|
|
||||||
|
@ -854,10 +854,15 @@ int mbedtls_ssl_derive_keys( mbedtls_ssl_context *ssl )
|
|||||||
#if defined(MBEDTLS_SSL_PROTO_TLS1) || defined(MBEDTLS_SSL_PROTO_TLS1_1) || \
|
#if defined(MBEDTLS_SSL_PROTO_TLS1) || defined(MBEDTLS_SSL_PROTO_TLS1_1) || \
|
||||||
defined(MBEDTLS_SSL_PROTO_TLS1_2)
|
defined(MBEDTLS_SSL_PROTO_TLS1_2)
|
||||||
if( ssl->minor_ver >= MBEDTLS_SSL_MINOR_VERSION_1 )
|
if( ssl->minor_ver >= MBEDTLS_SSL_MINOR_VERSION_1 )
|
||||||
|
{
|
||||||
|
/* For HMAC-based ciphersuites, initialize the HMAC transforms.
|
||||||
|
For AEAD-based ciphersuites, there is nothing to do here. */
|
||||||
|
if( mac_key_len != 0 )
|
||||||
{
|
{
|
||||||
mbedtls_md_hmac_starts( &transform->md_ctx_enc, mac_enc, mac_key_len );
|
mbedtls_md_hmac_starts( &transform->md_ctx_enc, mac_enc, mac_key_len );
|
||||||
mbedtls_md_hmac_starts( &transform->md_ctx_dec, mac_dec, mac_key_len );
|
mbedtls_md_hmac_starts( &transform->md_ctx_dec, mac_dec, mac_key_len );
|
||||||
}
|
}
|
||||||
|
}
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user