mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-07-28 00:21:48 +03:00
Merge pull request #7933 from tom-cosgrove-arm/add-mbedtls_zeroize_and_free
Provide and use internal function mbedtls_zeroize_and_free()
This commit is contained in:
@ -5830,8 +5830,7 @@ static void ssl_buffering_free_slot(mbedtls_ssl_context *ssl,
|
||||
|
||||
if (hs_buf->is_valid == 1) {
|
||||
hs->buffering.total_bytes_buffered -= hs_buf->data_len;
|
||||
mbedtls_platform_zeroize(hs_buf->data, hs_buf->data_len);
|
||||
mbedtls_free(hs_buf->data);
|
||||
mbedtls_zeroize_and_free(hs_buf->data, hs_buf->data_len);
|
||||
memset(hs_buf, 0, sizeof(mbedtls_ssl_hs_buffer));
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user