summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortb <>2020-01-24 09:42:32 +0000
committertb <>2020-01-24 09:42:32 +0000
commitd9f20373ce9d8f4c452f2170c07f26f940778379 (patch)
treef87e08cc9bd52fa96260c80e1f5434b687c77f95
parent659ab6a1018ad8fc2cd5c5801af96bdb482f623b (diff)
downloadopenbsd-d9f20373ce9d8f4c452f2170c07f26f940778379.tar.gz
openbsd-d9f20373ce9d8f4c452f2170c07f26f940778379.tar.bz2
openbsd-d9f20373ce9d8f4c452f2170c07f26f940778379.zip
Teach openssl s_client a bit about TLSv1.3.
ok beck jsing
-rw-r--r--src/usr.bin/openssl/s_cb.c19
1 files changed, 17 insertions, 2 deletions
diff --git a/src/usr.bin/openssl/s_cb.c b/src/usr.bin/openssl/s_cb.c
index ec25515bf2..79510cf571 100644
--- a/src/usr.bin/openssl/s_cb.c
+++ b/src/usr.bin/openssl/s_cb.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: s_cb.c,v 1.11 2018/11/06 05:45:50 jsing Exp $ */ 1/* $OpenBSD: s_cb.c,v 1.12 2020/01/24 09:42:32 tb Exp $ */
2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) 2/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com)
3 * All rights reserved. 3 * All rights reserved.
4 * 4 *
@@ -406,6 +406,9 @@ msg_cb(int write_p, int version, int content_type, const void *buf, size_t len,
406 case TLS1_2_VERSION: 406 case TLS1_2_VERSION:
407 str_version = "TLS 1.2 "; 407 str_version = "TLS 1.2 ";
408 break; 408 break;
409 case TLS1_3_VERSION:
410 str_version = "TLS 1.3 ";
411 break;
409 case DTLS1_VERSION: 412 case DTLS1_VERSION:
410 str_version = "DTLS 1.0 "; 413 str_version = "DTLS 1.0 ";
411 break; 414 break;
@@ -469,7 +472,7 @@ msg_cb(int write_p, int version, int content_type, const void *buf, size_t len,
469 } 472 }
470 if (version == SSL3_VERSION || version == TLS1_VERSION || 473 if (version == SSL3_VERSION || version == TLS1_VERSION ||
471 version == TLS1_1_VERSION || version == TLS1_2_VERSION || 474 version == TLS1_1_VERSION || version == TLS1_2_VERSION ||
472 version == DTLS1_VERSION) { 475 version == TLS1_3_VERSION || version == DTLS1_VERSION) {
473 switch (content_type) { 476 switch (content_type) {
474 case 20: 477 case 20:
475 str_content_type = "ChangeCipherSpec"; 478 str_content_type = "ChangeCipherSpec";
@@ -604,6 +607,15 @@ msg_cb(int write_p, int version, int content_type, const void *buf, size_t len,
604 case 3: 607 case 3:
605 str_details1 = ", HelloVerifyRequest"; 608 str_details1 = ", HelloVerifyRequest";
606 break; 609 break;
610 case 4:
611 str_details1 = ", NewSessionTicket";
612 break;
613 case 5:
614 str_details1 = ", EndOfEarlyData";
615 break;
616 case 8:
617 str_details1 = ", EncryptedExtensions";
618 break;
607 case 11: 619 case 11:
608 str_details1 = ", Certificate"; 620 str_details1 = ", Certificate";
609 break; 621 break;
@@ -625,6 +637,9 @@ msg_cb(int write_p, int version, int content_type, const void *buf, size_t len,
625 case 20: 637 case 20:
626 str_details1 = ", Finished"; 638 str_details1 = ", Finished";
627 break; 639 break;
640 case 24:
641 str_details1 = ", KeyUpdate";
642 break;
628 } 643 }
629 } 644 }
630 } 645 }