mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-23 19:35:42 +01:00
Move debugging output after record decryption
The debugging call printing the decrypted record payload happened before updating ssl->in_msglen.
This commit is contained in:
parent
d300003b2c
commit
a795323cd5
@ -4340,13 +4340,14 @@ static int ssl_prepare_record_content( mbedtls_ssl_context *ssl )
|
|||||||
return( ret );
|
return( ret );
|
||||||
}
|
}
|
||||||
|
|
||||||
MBEDTLS_SSL_DEBUG_BUF( 4, "input payload after decrypt",
|
|
||||||
ssl->in_msg, ssl->in_msglen );
|
|
||||||
|
|
||||||
ssl->in_msglen = rec.data_len;
|
ssl->in_msglen = rec.data_len;
|
||||||
ssl->in_len[0] = (unsigned char)( rec.data_len >> 8 );
|
ssl->in_len[0] = (unsigned char)( rec.data_len >> 8 );
|
||||||
ssl->in_len[1] = (unsigned char)( rec.data_len );
|
ssl->in_len[1] = (unsigned char)( rec.data_len );
|
||||||
|
|
||||||
|
MBEDTLS_SSL_DEBUG_BUF( 4, "input payload after decrypt",
|
||||||
|
ssl->in_msg, ssl->in_msglen );
|
||||||
|
|
||||||
if( ssl->in_msglen > MBEDTLS_SSL_IN_CONTENT_LEN )
|
if( ssl->in_msglen > MBEDTLS_SSL_IN_CONTENT_LEN )
|
||||||
{
|
{
|
||||||
MBEDTLS_SSL_DEBUG_MSG( 1, ( "bad message length" ) );
|
MBEDTLS_SSL_DEBUG_MSG( 1, ( "bad message length" ) );
|
||||||
|
Loading…
Reference in New Issue
Block a user