1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-07-30 22:43:08 +03:00

Add checking to missed case of calc_finished()

Signed-off-by: David Horstmann <david.horstmann@arm.com>
This commit is contained in:
David Horstmann
2025-03-11 18:13:02 +00:00
parent 78302e263c
commit 2b85729d23

View File

@ -3677,7 +3677,11 @@ int mbedtls_ssl_parse_finished(mbedtls_ssl_context *ssl)
#endif #endif
hash_len = 12; hash_len = 12;
ssl->handshake->calc_finished(ssl, buf, ssl->conf->endpoint ^ 1); ret = ssl->handshake->calc_finished(ssl, buf, ssl->conf->endpoint ^ 1);
if (ret != 0) {
MBEDTLS_SSL_DEBUG_RET(1, "calc_finished", ret);
goto exit;
}
if ((ret = mbedtls_ssl_read_record(ssl, 1)) != 0) { if ((ret = mbedtls_ssl_read_record(ssl, 1)) != 0) {
MBEDTLS_SSL_DEBUG_RET(1, "mbedtls_ssl_read_record", ret); MBEDTLS_SSL_DEBUG_RET(1, "mbedtls_ssl_read_record", ret);