TLS handshake appears to take a while :
What could cause (or fix) this ?I (21260) TLS loop: Start handshake ...
I (28470) TLS loop: SSL/TLS handshake ok
Thanks,
Danny
Code: Select all
ESP_LOGI(tls_tag, "Start handshake ..." );
if ((ret = mbedtls_ssl_handshake(&ssl)) != 0) {
if (ret != MBEDTLS_ERR_SSL_WANT_READ && ret != MBEDTLS_ERR_SSL_WANT_WRITE) {
mbedtls_strerror(ret, error_buf, sizeof(error_buf));
ESP_LOGE(tls_tag, "SSL/TLS handshake failed, error %d (%s)", ret, error_buf);
continue;
}
}
ESP_LOGI(tls_tag, "SSL/TLS handshake ok");