From owner-svn-ports-all@freebsd.org Thu Feb 18 09:22:43 2021 Return-Path: Delivered-To: svn-ports-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 1D8B3530D7D; Thu, 18 Feb 2021 09:22:43 +0000 (UTC) (envelope-from brnrd@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Dh8Pb0Mwcz3jwk; Thu, 18 Feb 2021 09:22:43 +0000 (UTC) (envelope-from brnrd@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id F3BD315EE0; Thu, 18 Feb 2021 09:22:42 +0000 (UTC) (envelope-from brnrd@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 11I9Mgk1078348; Thu, 18 Feb 2021 09:22:42 GMT (envelope-from brnrd@FreeBSD.org) Received: (from brnrd@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 11I9MgFk078346; Thu, 18 Feb 2021 09:22:42 GMT (envelope-from brnrd@FreeBSD.org) Message-Id: <202102180922.11I9MgFk078346@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: brnrd set sender to brnrd@FreeBSD.org using -f From: Bernard Spil Date: Thu, 18 Feb 2021 09:22:42 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r565914 - in head/security/openssl: . files X-SVN-Group: ports-head X-SVN-Commit-Author: brnrd X-SVN-Commit-Paths: in head/security/openssl: . files X-SVN-Commit-Revision: 565914 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 18 Feb 2021 09:22:43 -0000 Author: brnrd Date: Thu Feb 18 09:22:42 2021 New Revision: 565914 URL: https://svnweb.freebsd.org/changeset/ports/565914 Log: security/openssl: Update KTLS patch PR: 251969 Submitted by: gonzo, jhb Obtained from: https://github.com/openssl/openssl/commit/dfcfd17f2818cf520ce6381aed9ec3d2fc12170d Differential Revision: https://reviews.freebsd.org/D28763 Modified: head/security/openssl/Makefile head/security/openssl/files/extra-patch-ktls Modified: head/security/openssl/Makefile ============================================================================== --- head/security/openssl/Makefile Thu Feb 18 09:08:29 2021 (r565913) +++ head/security/openssl/Makefile Thu Feb 18 09:22:42 2021 (r565914) @@ -3,6 +3,7 @@ PORTNAME= openssl PORTVERSION= 1.1.1j +PORTREVISION= 1 PORTEPOCH= 1 CATEGORIES= security devel MASTER_SITES= https://www.openssl.org/source/ \ Modified: head/security/openssl/files/extra-patch-ktls ============================================================================== --- head/security/openssl/files/extra-patch-ktls Thu Feb 18 09:08:29 2021 (r565913) +++ head/security/openssl/files/extra-patch-ktls Thu Feb 18 09:22:42 2021 (r565914) @@ -1,8 +1,8 @@ diff --git CHANGES CHANGES -index 37dd60b726..4d61c1dadb 100644 +index 1ab64b35c9..a4a63a9bea 100644 --- CHANGES +++ CHANGES -@@ -390,6 +390,11 @@ +@@ -427,6 +427,11 @@ necessary to configure just to create a source distribution. [Richard Levitte] @@ -15,7 +15,7 @@ index 37dd60b726..4d61c1dadb 100644 *) Timing vulnerability in DSA signature generation diff --git Configure Configure -index 1d73d06e1b..29e655da96 100755 +index b286dd0678..f66f6bb3b1 100755 --- Configure +++ Configure @@ -341,6 +341,7 @@ my @dtls = qw(dtls1 dtls1_2); @@ -69,10 +69,10 @@ index 1d73d06e1b..29e655da96 100755 # do this late because some of them depend on %disabled. diff --git INSTALL INSTALL -index f5118428b3..be84f2aa8e 100644 +index f3ac727183..f6f754fd5e 100644 --- INSTALL +++ INSTALL -@@ -262,6 +262,15 @@ +@@ -263,6 +263,15 @@ Don't build the AFALG engine. This option will be forced if on a platform that does not support AFALG. @@ -350,7 +350,7 @@ index 6251f3d46a..a1fc23c7c9 100644 ret = (b->flags & BIO_FLAGS_IN_EOF) != 0 ? 1 : 0; break; diff --git crypto/err/openssl.txt crypto/err/openssl.txt -index 815460b24f..d547c45913 100644 +index 7e1776375d..b22e8a735c 100644 --- crypto/err/openssl.txt +++ crypto/err/openssl.txt @@ -1318,6 +1318,7 @@ SSL_F_SSL_RENEGOTIATE:516:SSL_renegotiate @@ -518,7 +518,7 @@ index 13e56f0c57..247a39fc03 100644 Copyright 2017-2019 The OpenSSL Project Authors. All Rights Reserved. diff --git doc/man3/SSL_write.pod doc/man3/SSL_write.pod -index 5e3ce1e7e4..20c7953deb 100644 +index 5e3ce1e7e4..9b271d8e65 100644 --- doc/man3/SSL_write.pod +++ doc/man3/SSL_write.pod @@ -2,12 +2,13 @@ @@ -551,7 +551,7 @@ index 5e3ce1e7e4..20c7953deb 100644 =head1 NOTES In the paragraphs below a "write function" is defined as one of either -@@ -104,17 +113,35 @@ You should instead call SSL_get_error() to find out if it's retryable. +@@ -104,17 +113,36 @@ You should instead call SSL_get_error() to find out if it's retryable. =back @@ -562,7 +562,8 @@ index 5e3ce1e7e4..20c7953deb 100644 +=item Z<>>= 0 + +The write operation was successful, the return value is the number -+of bytes of the file written to the TLS/SSL connection. ++of bytes of the file written to the TLS/SSL connection. The return ++value can be less than B for a partial write. + +=item E 0 + @@ -665,10 +666,10 @@ index c343b27629..521b5fa219 100644 +#endif diff --git include/internal/ktls.h include/internal/ktls.h new file mode 100644 -index 0000000000..9032c0ed61 +index 0000000000..622d7be76d --- /dev/null +++ include/internal/ktls.h -@@ -0,0 +1,403 @@ +@@ -0,0 +1,400 @@ +/* + * Copyright 2018 The OpenSSL Project Authors. All Rights Reserved. + * @@ -863,15 +864,12 @@ index 0000000000..9032c0ed61 +static ossl_inline ossl_ssize_t ktls_sendfile(int s, int fd, off_t off, + size_t size, int flags) +{ -+ off_t sbytes; ++ off_t sbytes = 0; + int ret; + + ret = sendfile(fd, s, off, size, NULL, &sbytes, flags); -+ if (ret == -1) { -+ if (errno == EAGAIN && sbytes != 0) -+ return sbytes; -+ return -1; -+ } ++ if (ret == -1 && sbytes == 0) ++ return -1; + return sbytes; +} + @@ -2084,7 +2082,7 @@ index 98057921f8..382f4b6d7b 100644 void SSL_set_record_padding_callback_arg(SSL *ssl, void *arg) diff --git ssl/ssl_local.h ssl/ssl_local.h -index 8ddbde7729..dc430fe40b 100644 +index 8c3542a542..c10e7d52ce 100644 --- ssl/ssl_local.h +++ ssl/ssl_local.h @@ -34,6 +34,8 @@ @@ -2096,7 +2094,7 @@ index 8ddbde7729..dc430fe40b 100644 # ifdef OPENSSL_BUILD_SHLIBSSL # undef OPENSSL_EXTERN -@@ -2618,6 +2620,17 @@ __owur int ssl_log_secret(SSL *ssl, const char *label, +@@ -2617,6 +2619,17 @@ __owur int ssl_log_secret(SSL *ssl, const char *label, #define EARLY_EXPORTER_SECRET_LABEL "EARLY_EXPORTER_SECRET" #define EXPORTER_SECRET_LABEL "EXPORTER_SECRET" @@ -2468,7 +2466,7 @@ index b8fb07f210..d9f050ee34 100644 return ret; } diff --git test/build.info test/build.info -index 56ac14eabd..e8454e2e03 100644 +index bc3dae81f9..e5ccaab5ba 100644 --- test/build.info +++ test/build.info @@ -544,7 +544,7 @@ INCLUDE_MAIN___test_libtestutil_OLB = /INCLUDE=MAIN @@ -2494,7 +2492,7 @@ index 5490885309..3478e540ed 100644 plan tests => 1; diff --git test/sslapitest.c test/sslapitest.c -index ad1824c68d..f6a61cab4e 100644 +index 4a27ee1ba2..f846bcb4ee 100644 --- test/sslapitest.c +++ test/sslapitest.c @@ -7,6 +7,7 @@ @@ -2929,7 +2927,7 @@ index ad1824c68d..f6a61cab4e 100644 static int test_large_message_tls(void) { return execute_test_large_message(TLS_server_method(), TLS_client_method(), -@@ -6691,6 +7097,12 @@ int setup_tests(void) +@@ -6747,6 +7153,12 @@ int setup_tests(void) return 0; }