Commit daccea61 authored by Dmitriy Zhuravlev's avatar Dmitriy Zhuravlev Committed by Randeep

Fix IOT-1465

Ownership transfer manager expects the CA_DTLS_AUTHENTICATION_FAILURE
in case of handshake error

Change-Id: I984ec32de52a0547e449d6b0580fa8299d678d8e
Signed-off-by: default avatarDmitriy Zhuravlev <d.zhuravlev@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/13641Tested-by: default avatarjenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Randeep's avatarRandeep Singh <randeep.s@samsung.com>
(cherry picked from commit af80659d)
Reviewed-on: https://gerrit.iotivity.org/gerrit/13651
parent 3a754782
......@@ -172,7 +172,14 @@ if (0 != (ret) && MBEDTLS_ERR_SSL_WANT_READ != (int) (ret) &&
{ \
mbedtls_ssl_send_alert_message(&(peer)->ssl, MBEDTLS_SSL_ALERT_LEVEL_FATAL, (msg)); \
} \
SSL_RES((peer), CA_STATUS_FAILED); \
if ((int) MBEDTLS_ERR_SSL_FATAL_ALERT_MESSAGE == (int) (ret) && \
((int) MBEDTLS_SSL_ALERT_MSG_DECRYPTION_FAILED == (peer)->ssl.in_msg[1] || \
(int) MBEDTLS_SSL_ALERT_MSG_DECRYPT_ERROR == (peer)->ssl.in_msg[1] || \
(int) MBEDTLS_SSL_ALERT_MSG_HANDSHAKE_FAILURE == (peer)->ssl.in_msg[1] || \
(int) MBEDTLS_SSL_ALERT_MSG_BAD_RECORD_MAC == (peer)->ssl.in_msg[1])) \
{ \
SSL_RES((peer), CA_DTLS_AUTHENTICATION_FAILURE); \
} \
RemovePeerFromList(&(peer)->sep.endpoint); \
if (mutex) \
{ \
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment