From ef69dcb649bbf6ef39ff629d4ba0711ff05b4d96 Mon Sep 17 00:00:00 2001 From: Hakase Date: Thu, 16 Aug 2018 01:04:10 +0900 Subject: [PATCH] Update pre9, Support TLS 1.3 final --- CHANGES | 67 ++++++++++++++++++++---- Configurations/15-android.conf | 3 ++ Configure | 2 - INSTALL | 10 ---- NEWS | 5 ++ crypto/asn1/a_object.c | 19 +++++-- crypto/asn1/asn1_err.c | 1 + crypto/conf/conf_ssl.c | 1 + crypto/err/openssl.txt | 1 + crypto/o_fopen.c | 18 +++++++ doc/man3/SSL_export_keying_material.pod | 3 +- include/openssl/asn1err.h | 1 + ssl/s3_lib.c | 4 +- ssl/statem/extensions_clnt.c | 3 +- ssl/statem/statem_lib.c | 19 ++++--- test/asynciotest.c | 4 +- test/recipes/30-test_evp_data/evpmac.txt | 45 ++++++++++++++++ test/recipes/70-test_sslcertstatus.t | 2 - test/recipes/70-test_sslversions.t | 7 ++- test/recipes/70-test_tls13downgrade.t | 4 -- util/perl/TLSProxy/Message.pm | 5 +- util/perl/TLSProxy/Record.pm | 1 - util/perl/TLSProxy/ServerHello.pm | 4 +- 23 files changed, 168 insertions(+), 61 deletions(-) diff --git a/CHANGES b/CHANGES index 8c67dab6..760160fa 100644 --- a/CHANGES +++ b/CHANGES @@ -225,16 +225,7 @@ *) Support for TLSv1.3 added. Note that users upgrading from an earlier version of OpenSSL should review their configuration settings to ensure that they are still appropriate for TLSv1.3. For further information see: - https://www.openssl.org/blog/blog/2018/02/08/tlsv1.3/ - - NOTE: In this pre-release of OpenSSL a draft version of the - TLSv1.3 standard has been implemented. Implementations of different draft - versions of the standard do not inter-operate, and this version will not - inter-operate with an implementation of the final standard when it is - eventually published. Different pre-release versions may implement - different versions of the draft. The final version of OpenSSL 1.1.1 will - implement the final version of the standard. - TODO(TLS1.3): Remove the above note before final release + https://wiki.openssl.org/index.php/TLS1.3 [Matt Caswell] *) Grand redesign of the OpenSSL random generator @@ -465,6 +456,62 @@ Changes between 1.1.0h and 1.1.0i [xx XXX xxxx] + *) Client DoS due to large DH parameter + + During key agreement in a TLS handshake using a DH(E) based ciphersuite a + malicious server can send a very large prime value to the client. This will + cause the client to spend an unreasonably long period of time generating a + key for this prime resulting in a hang until the client has finished. This + could be exploited in a Denial Of Service attack. + + This issue was reported to OpenSSL on 5th June 2018 by Guido Vranken + (CVE-2018-0732) + [Guido Vranken] + + *) Cache timing vulnerability in RSA Key Generation + + The OpenSSL RSA Key generation algorithm has been shown to be vulnerable to + a cache timing side channel attack. An attacker with sufficient access to + mount cache timing attacks during the RSA key generation process could + recover the private key. + + This issue was reported to OpenSSL on 4th April 2018 by Alejandro Cabrera + Aldaya, Billy Brumley, Cesar Pereida Garcia and Luis Manuel Alvarez Tapia. + (CVE-2018-0737) + [Billy Brumley] + + *) Make EVP_PKEY_asn1_new() a bit stricter about its input. A NULL pem_str + parameter is no longer accepted, as it leads to a corrupt table. NULL + pem_str is reserved for alias entries only. + [Richard Levitte] + + *) Revert blinding in ECDSA sign and instead make problematic addition + length-invariant. Switch even to fixed-length Montgomery multiplication. + [Andy Polyakov] + + *) Change generating and checking of primes so that the error rate of not + being prime depends on the intended use based on the size of the input. + For larger primes this will result in more rounds of Miller-Rabin. + The maximal error rate for primes with more than 1080 bits is lowered + to 2^-128. + [Kurt Roeckx, Annie Yousar] + + *) Increase the number of Miller-Rabin rounds for DSA key generating to 64. + [Kurt Roeckx] + + *) Add blinding to ECDSA and DSA signatures to protect against side channel + attacks discovered by Keegan Ryan (NCC Group). + [Matt Caswell] + + *) When unlocking a pass phrase protected PEM file or PKCS#8 container, we + now allow empty (zero character) pass phrases. + [Richard Levitte] + + *) Certificate time validation (X509_cmp_time) enforces stricter + compliance with RFC 5280. Fractional seconds and timezone offsets + are no longer allowed. + [Emilia Käsper] + *) Fixed a text canonicalisation bug in CMS Where a CMS detached signature is used with text content the text goes diff --git a/Configurations/15-android.conf b/Configurations/15-android.conf index ddd642a1..d3b428b6 100644 --- a/Configurations/15-android.conf +++ b/Configurations/15-android.conf @@ -4,6 +4,8 @@ # comments below... { + use File::Spec::Functions; + my $android_ndk = {}; my %triplet = ( arm => "arm-linux-androideabi", @@ -23,6 +25,7 @@ my $ndk = $ENV{ANDROID_NDK}; die "\$ANDROID_NDK is not defined" if (!$ndk); die "\$ANDROID_NDK=$ndk is invalid" if (!-d "$ndk/platforms"); + $ndk = canonpath($ndk); my $ndkver = undef; diff --git a/Configure b/Configure index 05927127..c9f6ea76 100755 --- a/Configure +++ b/Configure @@ -405,7 +405,6 @@ my @disablables = ( "tests", "threads", "tls", - "tls13downgrade", "ts", "ubsan", "ui-console", @@ -449,7 +448,6 @@ our %disabled = ( # "what" => "comment" "ssl3" => "default", "ssl3-method" => "default", "ubsan" => "default", - "tls13downgrade" => "default", "unit-test" => "default", "weak-ssl-ciphers" => "default", "zlib" => "default", diff --git a/INSTALL b/INSTALL index 34023dcd..ff0aa6d1 100644 --- a/INSTALL +++ b/INSTALL @@ -476,16 +476,6 @@ require additional system-dependent options! See "Note on multi-threading" below. - enable-tls13downgrade - TODO(TLS1.3): Make this enabled by default and remove the - option when TLSv1.3 is out of draft - TLSv1.3 offers a downgrade protection mechanism. This is - implemented but disabled by default. It should not typically - be enabled except for testing purposes. Otherwise this could - cause problems if a pre-RFC version of OpenSSL talks to an - RFC implementation (it will erroneously be detected as a - downgrade). - no-ts Don't build Time Stamping Authority support. diff --git a/NEWS b/NEWS index 60c841f3..1f98b931 100644 --- a/NEWS +++ b/NEWS @@ -22,6 +22,11 @@ o Add support for SipHash o Grand redesign of the OpenSSL random generator + Major changes between OpenSSL 1.1.0h and OpenSSL 1.1.0i [under development] + + o Client DoS due to large DH parameter (CVE-2018-0732) + o Cache timing vulnerability in RSA Key Generation (CVE-2018-0737) + Major changes between OpenSSL 1.1.0g and OpenSSL 1.1.0h [under development] o Constructed ASN.1 types with a recursive definition could exceed the diff --git a/crypto/asn1/a_object.c b/crypto/asn1/a_object.c index 42c138c2..5e1424a8 100644 --- a/crypto/asn1/a_object.c +++ b/crypto/asn1/a_object.c @@ -20,7 +20,7 @@ int i2d_ASN1_OBJECT(const ASN1_OBJECT *a, unsigned char **pp) { - unsigned char *p; + unsigned char *p, *allocated = NULL; int objsize; if ((a == NULL) || (a->data == NULL)) @@ -30,12 +30,23 @@ int i2d_ASN1_OBJECT(const ASN1_OBJECT *a, unsigned char **pp) if (pp == NULL || objsize == -1) return objsize; - p = *pp; + if (*pp == NULL) { + if ((p = allocated = OPENSSL_malloc(objsize)) == NULL) { + ASN1err(ASN1_F_I2D_ASN1_OBJECT, ERR_R_MALLOC_FAILURE); + return 0; + } + } else { + p = *pp; + } + ASN1_put_object(&p, 0, a->length, V_ASN1_OBJECT, V_ASN1_UNIVERSAL); memcpy(p, a->data, a->length); - p += a->length; - *pp = p; + /* + * If a new buffer was allocated, just return it back. + * If not, return the incremented buffer pointer. + */ + *pp = allocated != NULL ? allocated : p + a->length; return objsize; } diff --git a/crypto/asn1/asn1_err.c b/crypto/asn1/asn1_err.c index 5907c94b..613f9ae7 100644 --- a/crypto/asn1/asn1_err.c +++ b/crypto/asn1/asn1_err.c @@ -116,6 +116,7 @@ static const ERR_STRING_DATA ASN1_str_functs[] = { {ERR_PACK(ERR_LIB_ASN1, ASN1_F_I2A_ASN1_OBJECT, 0), "i2a_ASN1_OBJECT"}, {ERR_PACK(ERR_LIB_ASN1, ASN1_F_I2D_ASN1_BIO_STREAM, 0), "i2d_ASN1_bio_stream"}, + {ERR_PACK(ERR_LIB_ASN1, ASN1_F_I2D_ASN1_OBJECT, 0), "i2d_ASN1_OBJECT"}, {ERR_PACK(ERR_LIB_ASN1, ASN1_F_I2D_DSA_PUBKEY, 0), "i2d_DSA_PUBKEY"}, {ERR_PACK(ERR_LIB_ASN1, ASN1_F_I2D_EC_PUBKEY, 0), "i2d_EC_PUBKEY"}, {ERR_PACK(ERR_LIB_ASN1, ASN1_F_I2D_PRIVATEKEY, 0), "i2d_PrivateKey"}, diff --git a/crypto/conf/conf_ssl.c b/crypto/conf/conf_ssl.c index 015c46c6..024bdb48 100644 --- a/crypto/conf/conf_ssl.c +++ b/crypto/conf/conf_ssl.c @@ -76,6 +76,7 @@ static int ssl_module_init(CONF_IMODULE *md, const CONF *cnf) goto err; } cnt = sk_CONF_VALUE_num(cmd_lists); + ssl_module_free(md); ssl_names = OPENSSL_zalloc(sizeof(*ssl_names) * cnt); ssl_names_count = cnt; for (i = 0; i < ssl_names_count; i++) { diff --git a/crypto/err/openssl.txt b/crypto/err/openssl.txt index 90b5c4e0..3ecd44b5 100644 --- a/crypto/err/openssl.txt +++ b/crypto/err/openssl.txt @@ -88,6 +88,7 @@ ASN1_F_DO_DUMP:125:do_dump ASN1_F_DO_TCREATE:222:do_tcreate ASN1_F_I2A_ASN1_OBJECT:126:i2a_ASN1_OBJECT ASN1_F_I2D_ASN1_BIO_STREAM:211:i2d_ASN1_bio_stream +ASN1_F_I2D_ASN1_OBJECT:143:i2d_ASN1_OBJECT ASN1_F_I2D_DSA_PUBKEY:161:i2d_DSA_PUBKEY ASN1_F_I2D_EC_PUBKEY:181:i2d_EC_PUBKEY ASN1_F_I2D_PRIVATEKEY:163:i2d_PrivateKey diff --git a/crypto/o_fopen.c b/crypto/o_fopen.c index 1090a068..f08f99b4 100644 --- a/crypto/o_fopen.c +++ b/crypto/o_fopen.c @@ -7,6 +7,24 @@ * https://www.openssl.org/source/license.html */ +# if defined(__linux) || defined(__sun) || defined(__hpux) +/* + * Following definition aliases fopen to fopen64 on above mentioned + * platforms. This makes it possible to open and sequentially access files + * larger than 2GB from 32-bit application. It does not allow to traverse + * them beyond 2GB with fseek/ftell, but on the other hand *no* 32-bit + * platform permits that, not with fseek/ftell. Not to mention that breaking + * 2GB limit for seeking would require surgery to *our* API. But sequential + * access suffices for practical cases when you can run into large files, + * such as fingerprinting, so we can let API alone. For reference, the list + * of 32-bit platforms which allow for sequential access of large files + * without extra "magic" comprise *BSD, Darwin, IRIX... + */ +# ifndef _FILE_OFFSET_BITS +# define _FILE_OFFSET_BITS 64 +# endif +# endif + #include "internal/cryptlib.h" #if !defined(OPENSSL_NO_STDIO) diff --git a/doc/man3/SSL_export_keying_material.pod b/doc/man3/SSL_export_keying_material.pod index 0090097d..abebf911 100644 --- a/doc/man3/SSL_export_keying_material.pod +++ b/doc/man3/SSL_export_keying_material.pod @@ -26,8 +26,7 @@ During the creation of a TLS or DTLS connection shared keying material is established between the two endpoints. The functions SSL_export_keying_material() and SSL_export_keying_material_early() enable an application to use some of this keying material for its own purposes in -accordance with RFC5705 (for TLSv1.2 and below) or RFCXXXX (for TLSv1.3). -TODO(TLS1.3): Update the RFC number when the RFC is published. +accordance with RFC5705 (for TLSv1.2 and below) or RFC8446 (for TLSv1.3). SSL_export_keying_material() derives keying material using the F established in the handshake. diff --git a/include/openssl/asn1err.h b/include/openssl/asn1err.h index 8001120b..5a91126d 100644 --- a/include/openssl/asn1err.h +++ b/include/openssl/asn1err.h @@ -101,6 +101,7 @@ int ERR_load_ASN1_strings(void); # define ASN1_F_DO_TCREATE 222 # define ASN1_F_I2A_ASN1_OBJECT 126 # define ASN1_F_I2D_ASN1_BIO_STREAM 211 +# define ASN1_F_I2D_ASN1_OBJECT 143 # define ASN1_F_I2D_DSA_PUBKEY 161 # define ASN1_F_I2D_EC_PUBKEY 181 # define ASN1_F_I2D_PRIVATEKEY 163 diff --git a/ssl/s3_lib.c b/ssl/s3_lib.c index 6d86bb98..63a6cc61 100644 --- a/ssl/s3_lib.c +++ b/ssl/s3_lib.c @@ -4580,7 +4580,7 @@ int ssl_fill_hello_random(SSL *s, int server, unsigned char *result, size_t len, } else { ret = RAND_bytes(result, len); } -#ifndef OPENSSL_NO_TLS13DOWNGRADE + if (ret > 0) { if (!ossl_assert(sizeof(tls11downgrade) < len) || !ossl_assert(sizeof(tls12downgrade) < len)) @@ -4592,7 +4592,7 @@ int ssl_fill_hello_random(SSL *s, int server, unsigned char *result, size_t len, memcpy(result + len - sizeof(tls11downgrade), tls11downgrade, sizeof(tls11downgrade)); } -#endif + return ret; } diff --git a/ssl/statem/extensions_clnt.c b/ssl/statem/extensions_clnt.c index 4fb02935..a1defe74 100644 --- a/ssl/statem/extensions_clnt.c +++ b/ssl/statem/extensions_clnt.c @@ -538,7 +538,8 @@ EXT_RETURN tls_construct_ctos_supported_versions(SSL *s, WPACKET *pkt, for (currv = max_version; currv >= min_version; currv--) { /* TODO(TLS1.3): Remove this first if clause prior to release!! */ if (currv == TLS1_3_VERSION) { - if (!WPACKET_put_bytes_u16(pkt, TLS1_3_VERSION_DRAFT) + if (!WPACKET_put_bytes_u16(pkt, TLS1_3_VERSION) + || !WPACKET_put_bytes_u16(pkt, TLS1_3_VERSION_DRAFT) || !WPACKET_put_bytes_u16(pkt, TLS1_3_VERSION_DRAFT_27) || !WPACKET_put_bytes_u16(pkt, TLS1_3_VERSION_DRAFT_26) || !WPACKET_put_bytes_u16(pkt, TLS1_3_VERSION_DRAFT_23)) { diff --git a/ssl/statem/statem_lib.c b/ssl/statem/statem_lib.c index 88258215..df0a3983 100644 --- a/ssl/statem/statem_lib.c +++ b/ssl/statem/statem_lib.c @@ -381,9 +381,6 @@ MSG_PROCESS_RETURN tls_process_cert_verify(SSL *s, PACKET *pkt) /* SSLfatal() already called */ goto err; } -#ifdef SSL_DEBUG - fprintf(stderr, "USING TLSv1.2 HASH %s\n", EVP_MD_name(md)); -#endif } else if (!tls1_set_peer_legacy_sigalg(s, pkey)) { SSLfatal(s, SSL_AD_INTERNAL_ERROR, SSL_F_TLS_PROCESS_CERT_VERIFY, ERR_R_INTERNAL_ERROR); @@ -396,6 +393,11 @@ MSG_PROCESS_RETURN tls_process_cert_verify(SSL *s, PACKET *pkt) goto err; } +#ifdef SSL_DEBUG + if (SSL_USE_SIGALGS(s)) + fprintf(stderr, "USING TLSv1.2 HASH %s\n", EVP_MD_name(md)); +#endif + /* Check for broken implementations of GOST ciphersuites */ /* * If key is GOST and len is exactly 64 or 128, it is signature without @@ -1764,17 +1766,16 @@ int ssl_choose_server_version(SSL *s, CLIENTHELLO_MSG *hello, DOWNGRADE *dgrd) while (PACKET_get_net_2(&versionslist, &candidate_vers)) { /* TODO(TLS1.3): Remove this before release */ - if (candidate_vers == TLS1_3_VERSION_DRAFT + if (candidate_vers == TLS1_3_VERSION + || candidate_vers == TLS1_3_VERSION_DRAFT || candidate_vers == TLS1_3_VERSION_DRAFT_26 || candidate_vers == TLS1_3_VERSION_DRAFT_23) { if (best_vers == TLS1_3_VERSION - && orig_candidate > candidate_vers) + && (orig_candidate > candidate_vers + || orig_candidate == TLS1_3_VERSION)) continue; orig_candidate = candidate_vers; candidate_vers = TLS1_3_VERSION; - } else if (candidate_vers == TLS1_3_VERSION) { - /* Don't actually accept real TLSv1.3 */ - continue; } /* * TODO(TLS1.3): There is some discussion on the TLS list about @@ -1935,7 +1936,6 @@ int ssl_choose_client_version(SSL *s, int version, RAW_EXTENSION *extensions) if (s->version != vent->version) continue; -#ifndef OPENSSL_NO_TLS13DOWNGRADE /* Check for downgrades */ if (s->version == TLS1_2_VERSION && highver > s->version) { if (memcmp(tls12downgrade, @@ -1962,7 +1962,6 @@ int ssl_choose_client_version(SSL *s, int version, RAW_EXTENSION *extensions) return 0; } } -#endif s->method = method; return 1; diff --git a/test/asynciotest.c b/test/asynciotest.c index 73e415fd..5e85cbb0 100644 --- a/test/asynciotest.c +++ b/test/asynciotest.c @@ -227,11 +227,9 @@ static int async_write(BIO *bio, const char *in, int inl) /* * We can't fragment anything after the ServerHello (or CCS <= * TLS1.2), otherwise we get a bad record MAC - * TODO(TLS1.3): Change TLS1_3_VERSION_DRAFT to TLS1_3_VERSION - * before release */ if (contenttype == SSL3_RT_CHANGE_CIPHER_SPEC - || (negversion == TLS1_3_VERSION_DRAFT + || (negversion == TLS1_3_VERSION && msgtype == SSL3_MT_SERVER_HELLO)) { fragment = 0; break; diff --git a/test/recipes/30-test_evp_data/evpmac.txt b/test/recipes/30-test_evp_data/evpmac.txt index cd6a3d0c..ef7ba940 100644 --- a/test/recipes/30-test_evp_data/evpmac.txt +++ b/test/recipes/30-test_evp_data/evpmac.txt @@ -148,6 +148,8 @@ Key = AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA Input = DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD Output = 56be34521d144c88dbb8c733f0e8b3f6 +Title = SHA1 + # HMAC tests from NIST test data MAC = HMAC @@ -168,6 +170,8 @@ Input = "Sample message for keylen=blocklen" Key = 000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F202122232425262728292A2B2C2D2E2F303132333435363738393A3B3C3D3E3F404142434445464748494A4B4C4D4E4F505152535455565758595A5B5C5D5E5F60616263 Output = 2D51B2F7750E410584662E38F133435F4C4FD42A +Title = SHA2 + MAC = HMAC Algorithm = SHA224 Input = "Sample message for keylen=blocklen" @@ -240,6 +244,47 @@ Input = "Sample message for keylen=blocklen" Key = 000102030405060708090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F202122232425262728292A2B2C2D2E2F303132333435363738393A3B3C3D3E3F404142434445464748494A4B4C4D4E4F505152535455565758595A5B5C5D5E5F606162636465666768696A6B6C6D6E6F707172737475767778797A7B7C7D7E7F808182838485868788898A8B8C8D8E8F909192939495969798999A9B9C9D9E9FA0A1A2A3A4A5A6A7A8A9AAABACADAEAFB0B1B2B3B4B5B6B7B8B9BABBBCBDBEBFC0C1C2C3C4C5C6C7 Output = D93EC8D2DE1AD2A9957CB9B83F14E76AD6B5E0CCE285079A127D3B14BCCB7AA7286D4AC0D4CE64215F2BC9E6870B33D97438BE4AAA20CDA5C5A912B48B8E27F3 +Title = SHA3 + +# NIST's test vectors + +MAC = HMAC +Algorithm = SHA3-384 +Input = "Sample message for keylennew( #Test 1: Sending a status_request extension in both ClientHello and #ServerHello but then omitting the CertificateStatus message is valid -#TODO(TLS1.3): Temporarily disabling this test in TLS1.3 until we've completed -#the move the status request extension to the Certificate message. $proxy->clientflags("-status -no_tls1_3"); $proxy->start() or plan skip_all => "Unable to start up Proxy for tests"; plan tests => 1; diff --git a/test/recipes/70-test_sslversions.t b/test/recipes/70-test_sslversions.t index 8ef85af7..c2d76239 100644 --- a/test/recipes/70-test_sslversions.t +++ b/test/recipes/70-test_sslversions.t @@ -145,8 +145,7 @@ sub modify_supported_versions_filter $ext = pack "C5", 0x04, # Length 0x03, 0x03, #TLSv1.2 - #TODO(TLS1.3): Fix before release - 0x7f, 0x1c; #TLSv1.3 (draft 28) + 0x03, 0x04; #TLSv1.3 } elsif ($testtype == UNRECOGNISED_VERSIONS) { $ext = pack "C5", 0x04, # Length @@ -160,8 +159,8 @@ sub modify_supported_versions_filter } elsif ($testtype == WITH_TLS1_4) { $ext = pack "C5", 0x04, # Length - #TODO(TLS1.3): Fix before release - 0x7f, 0x1c; #TLSv1.3 (draft 28) + 0x03, 0x05, #TLSv1.4 + 0x03, 0x04; #TLSv1.3 } if ($testtype == REVERSE_ORDER_VERSIONS || $testtype == UNRECOGNISED_VERSIONS diff --git a/test/recipes/70-test_tls13downgrade.t b/test/recipes/70-test_tls13downgrade.t index cc5fb16d..f7c88123 100644 --- a/test/recipes/70-test_tls13downgrade.t +++ b/test/recipes/70-test_tls13downgrade.t @@ -26,10 +26,6 @@ plan skip_all => "$test_name needs the sock feature enabled" plan skip_all => "$test_name needs TLS1.3 and TLS1.2 enabled" if disabled("tls1_3") || disabled("tls1_2"); -# TODO(TLS1.3): Enable this when TLSv1.3 comes out of draft -plan skip_all => "$test_name not run in pre TLSv1.3 RFC implementation" - if disabled("tls13downgrade"); - $ENV{OPENSSL_ia32cap} = '~0x200000200000000'; my $proxy = TLSProxy::Proxy->new( diff --git a/util/perl/TLSProxy/Message.pm b/util/perl/TLSProxy/Message.pm index dae6daa6..16ed0120 100644 --- a/util/perl/TLSProxy/Message.pm +++ b/util/perl/TLSProxy/Message.pm @@ -95,9 +95,8 @@ use constant { EXT_FORCE_LAST => 0xffff }; -# SignatureScheme of TLS 1.3, from -# https://tools.ietf.org/html/draft-ietf-tls-tls13-20#appendix-B.3.1.3 -# TODO(TLS1.3) update link to IANA registry after publication +# SignatureScheme of TLS 1.3 from: +# https://www.iana.org/assignments/tls-parameters/tls-parameters.xhtml#tls-signaturescheme # We have to manually grab the SHA224 equivalents from the old registry use constant { SIG_ALG_RSA_PKCS1_SHA256 => 0x0401, diff --git a/util/perl/TLSProxy/Record.pm b/util/perl/TLSProxy/Record.pm index 8db50d0b..0a280cb2 100644 --- a/util/perl/TLSProxy/Record.pm +++ b/util/perl/TLSProxy/Record.pm @@ -36,7 +36,6 @@ my %record_type = ( use constant { VERS_TLS_1_4 => 0x0305, - VERS_TLS_1_3_DRAFT => 0x7f1c, VERS_TLS_1_3 => 0x0304, VERS_TLS_1_2 => 0x0303, VERS_TLS_1_1 => 0x0302, diff --git a/util/perl/TLSProxy/ServerHello.pm b/util/perl/TLSProxy/ServerHello.pm index 934eaf4d..232c778b 100644 --- a/util/perl/TLSProxy/ServerHello.pm +++ b/util/perl/TLSProxy/ServerHello.pm @@ -101,9 +101,7 @@ sub parse if ($random eq $hrrrandom) { TLSProxy::Proxy->is_tls13(1); - # TODO(TLS1.3): Replace this reference to draft version before release - } elsif ($neg_version == TLSProxy::Record::VERS_TLS_1_3_DRAFT) { - $neg_version = TLSProxy::Record::VERS_TLS_1_3; + } elsif ($neg_version == TLSProxy::Record::VERS_TLS_1_3) { TLSProxy::Proxy->is_tls13(1); TLSProxy::Record->server_encrypting(1);