diff options
author | Daniel Jelinski <djelinski1@gmail.com> | 2018-08-06 23:35:33 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2018-08-09 12:31:24 +0200 |
commit | aa2ad90acd05903217e108e2584006acc651b5d6 (patch) | |
tree | 9d4eb14269493c8b575427bca6597908dc020d5c | |
parent | 3668d9d76232678007efe25f5a761d80b37a0f3e (diff) |
openssl: fix debug messages
Fixes #2806
Closes #2843
-rw-r--r-- | lib/vtls/openssl.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/lib/vtls/openssl.c b/lib/vtls/openssl.c index 9ce1ae5ab..f747db9ac 100644 --- a/lib/vtls/openssl.c +++ b/lib/vtls/openssl.c @@ -1974,7 +1974,15 @@ static void ssl_tls_trace(int direction, int ssl_ver, int content_type, } else #endif - { + if(content_type == SSL3_RT_CHANGE_CIPHER_SPEC) { + msg_type = *(char *)buf; + msg_name = "Change cipher spec"; + } + else if(content_type == SSL3_RT_ALERT) { + msg_type = (((char *)buf)[0] << 8) + ((char *)buf)[1]; + msg_name = SSL_alert_desc_string_long(msg_type); + } + else { msg_type = *(char *)buf; msg_name = ssl_msg_type(ssl_ver, msg_type); } |