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

Add interface for truncated hmac

This commit is contained in:
Manuel Pégourié-Gonnard
2013-07-19 11:08:52 +02:00
committed by Paul Bakker
parent 5b55b79021
commit e980a994f0
3 changed files with 37 additions and 0 deletions

View File

@ -3141,6 +3141,16 @@ int ssl_set_max_frag_len( ssl_context *ssl, unsigned char mfl_code )
return( 0 );
}
int ssl_set_truncated_hmac( ssl_context *ssl )
{
if( ssl->endpoint != SSL_IS_CLIENT )
return( POLARSSL_ERR_SSL_BAD_INPUT_DATA );
ssl->trunc_hmac = SSL_TRUNC_HMAC_ENABLED;
return( 0 );
}
void ssl_set_renegotiation( ssl_context *ssl, int renegotiation )
{
ssl->disable_renegotiation = renegotiation;