From nobody Wed Jan 31 19:55:02 2024 X-Original-To: dev-commits-ports-branches@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4TQCS71q6Kz589Kw; Wed, 31 Jan 2024 19:55:03 +0000 (UTC) (envelope-from git@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 4TQCS71KNGz4f5f; Wed, 31 Jan 2024 19:55:03 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1706730903; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XFAtojofnINFUfF7MLgz1o0boyGOwy1MPv8fyWth5uQ=; b=pHRTaBW4T+WOU2AwOAvlzvpWsF3PSrGKd1YUJ0Kw0OMHM3nRC/a8NjT2lpKRclBDRuvX+4 /hJ6Kr9xsl/PObhPWnxq357j//2FkkL6v7jcIFUqbPZHxO8sjOhZSQ2FZYVzXDnsZe0r5I wzSmQqVPrxv45ZON3T23qLXEXTIQQcZPqqOQCUOtMeWAakfO6w1X74Qrav3pBAtfVIex/t PSuYy6ItRyVMHrpiSB8g87Cz/XmbvNcs+reUm1C4ew2ZiV3SWyLcKzztRUQKGNNGgnBegr A102nFQFUn0iJoiiUB/9zr0346wrdr1YOFRkHjQ4ryFfyPiEhUbCAB5K9oTKUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1706730903; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=XFAtojofnINFUfF7MLgz1o0boyGOwy1MPv8fyWth5uQ=; b=MrfGgFuid3GkxmUHfpAB7cjk1T+dlw7MiovMo+KOYB0YNccfn6rSByDEf0mVNf56yCGTB6 qRZ3TjwX3i44XdN4y/cnZvfSDPq08hY75M7cz9LbtwnjnqWTVOkGPl7ZjAnUStnTlsoQzQ 73NmXJadEXaxine1JV/O9AatEBR8m6i703ousPvZ0MJ+uDbD4mCQhgAojLbmbKf3Pvy5a2 Kr3YcyQp+Mb/5D/ZdtDZ8sAXPyrwN6lo5bJn9lSZkFvBt3fST65DnbXOfZ6LpLhfkpnj04 eHNzfFrzvZf+oId/7aBe2kPe9oD8ZYiPk4WhQUE3h9lVHEAyrz4xx8YQm8332w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1706730903; a=rsa-sha256; cv=none; b=Jcgfgi/7Mqvsn5LlRWSruVwCqQFZJUqXAoBA7W6mZPWseTDw2NvSJZcWzFIgs8CERlyhkj 2iG+jHpaUj0BdKrCp/1pdQm3d+oJK+m5Mg7o0eoU7Xm/cXOmhxvxseGoCbbhOT28qZXko/ A27OiJjLNOhpvPUokbdmYRPZSwfrJFeidNqG9b7va8L801B2F7B4uMoTayV2WCFnFKUxz8 iNAmkc8CVZh85WnUq6iDnCr4QZFDuJPx1w0PVb3EwJidxNVhFho2Lpn+r0wAfFyIp8JLQx WzsgxtB5SIkBt7M+Hv1JtbRAqohQA7xIBnaWC/dpzjdsWqzva4e6eFOg0Ld2Bg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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 did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4TQCS704sfzXqf; Wed, 31 Jan 2024 19:55:03 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 40VJt2NK098962; Wed, 31 Jan 2024 19:55:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 40VJt2X2098959; Wed, 31 Jan 2024 19:55:02 GMT (envelope-from git) Date: Wed, 31 Jan 2024 19:55:02 GMT Message-Id: <202401311955.40VJt2X2098959@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-branches@FreeBSD.org From: Bernard Spil Subject: git: 96c28e9f1fc7 - 2024Q1 - security/openssl31-quictls: Security fix for POLY1305 on ppc List-Id: Commits to the quarterly branches of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-branches@freebsd.org X-BeenThere: dev-commits-ports-branches@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: brnrd X-Git-Repository: ports X-Git-Refname: refs/heads/2024Q1 X-Git-Reftype: branch X-Git-Commit: 96c28e9f1fc70a717689c91a4eaa8518acc5a550 Auto-Submitted: auto-generated The branch 2024Q1 has been updated by brnrd: URL: https://cgit.FreeBSD.org/ports/commit/?id=96c28e9f1fc70a717689c91a4eaa8518acc5a550 commit 96c28e9f1fc70a717689c91a4eaa8518acc5a550 Author: Bernard Spil AuthorDate: 2024-01-11 12:46:47 +0000 Commit: Bernard Spil CommitDate: 2024-01-31 19:54:21 +0000 security/openssl31-quictls: Security fix for POLY1305 on ppc Security: 8337251b-b07b-11ee-b0d7-84a93843eb75 MFH: 2024Q1 (cherry picked from commit 130b9ff2a3a69e6b8472edc135d81f8129d32e17) --- security/openssl31-quictls/Makefile | 2 +- .../openssl31-quictls/files/patch-CVE-2023-6129 | 109 +++++++++++++++++++++ 2 files changed, 110 insertions(+), 1 deletion(-) diff --git a/security/openssl31-quictls/Makefile b/security/openssl31-quictls/Makefile index 19bfd5545a73..a1c5f1465e3d 100644 --- a/security/openssl31-quictls/Makefile +++ b/security/openssl31-quictls/Makefile @@ -1,6 +1,6 @@ PORTNAME= openssl PORTVERSION= 3.1.4 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= security devel PKGNAMESUFFIX= 31-quictls diff --git a/security/openssl31-quictls/files/patch-CVE-2023-6129 b/security/openssl31-quictls/files/patch-CVE-2023-6129 new file mode 100644 index 000000000000..ed1b41586234 --- /dev/null +++ b/security/openssl31-quictls/files/patch-CVE-2023-6129 @@ -0,0 +1,109 @@ +From f3fc5808fe9ff74042d639839610d03b8fdcc015 Mon Sep 17 00:00:00 2001 +From: Rohan McLure +Date: Thu, 4 Jan 2024 10:25:50 +0100 +Subject: [PATCH] poly1305-ppc.pl: Fix vector register clobbering + +Fixes CVE-2023-6129 + +The POLY1305 MAC (message authentication code) implementation in OpenSSL for +PowerPC CPUs saves the the contents of vector registers in different order +than they are restored. Thus the contents of some of these vector registers +is corrupted when returning to the caller. The vulnerable code is used only +on newer PowerPC processors supporting the PowerISA 2.07 instructions. + +Reviewed-by: Matt Caswell +Reviewed-by: Richard Levitte +Reviewed-by: Tomas Mraz +(Merged from https://github.com/openssl/openssl/pull/23200) + +(cherry picked from commit 8d847a3ffd4f0b17ee33962cf69c36224925b34f) +--- + crypto/poly1305/asm/poly1305-ppc.pl | 42 ++++++++++++++--------------- + 1 file changed, 21 insertions(+), 21 deletions(-) + +diff --git a/crypto/poly1305/asm/poly1305-ppc.pl b/crypto/poly1305/asm/poly1305-ppc.pl +index 9f86134d923fb..2e601bb9c24be 100755 +--- crypto/poly1305/asm/poly1305-ppc.pl.orig ++++ crypto/poly1305/asm/poly1305-ppc.pl +@@ -744,7 +744,7 @@ + my $LOCALS= 6*$SIZE_T; + my $VSXFRAME = $LOCALS + 6*$SIZE_T; + $VSXFRAME += 128; # local variables +- $VSXFRAME += 13*16; # v20-v31 offload ++ $VSXFRAME += 12*16; # v20-v31 offload + + my $BIG_ENDIAN = ($flavour !~ /le/) ? 4 : 0; + +@@ -919,12 +919,12 @@ + addi r11,r11,32 + stvx v22,r10,$sp + addi r10,r10,32 +- stvx v23,r10,$sp +- addi r10,r10,32 +- stvx v24,r11,$sp ++ stvx v23,r11,$sp + addi r11,r11,32 +- stvx v25,r10,$sp ++ stvx v24,r10,$sp + addi r10,r10,32 ++ stvx v25,r11,$sp ++ addi r11,r11,32 + stvx v26,r10,$sp + addi r10,r10,32 + stvx v27,r11,$sp +@@ -1153,12 +1153,12 @@ + addi r11,r11,32 + stvx v22,r10,$sp + addi r10,r10,32 +- stvx v23,r10,$sp +- addi r10,r10,32 +- stvx v24,r11,$sp ++ stvx v23,r11,$sp + addi r11,r11,32 +- stvx v25,r10,$sp ++ stvx v24,r10,$sp + addi r10,r10,32 ++ stvx v25,r11,$sp ++ addi r11,r11,32 + stvx v26,r10,$sp + addi r10,r10,32 + stvx v27,r11,$sp +@@ -1899,26 +1899,26 @@ + mtspr 256,r12 # restore vrsave + lvx v20,r10,$sp + addi r10,r10,32 +- lvx v21,r10,$sp +- addi r10,r10,32 +- lvx v22,r11,$sp ++ lvx v21,r11,$sp + addi r11,r11,32 +- lvx v23,r10,$sp ++ lvx v22,r10,$sp + addi r10,r10,32 +- lvx v24,r11,$sp ++ lvx v23,r11,$sp + addi r11,r11,32 +- lvx v25,r10,$sp ++ lvx v24,r10,$sp + addi r10,r10,32 +- lvx v26,r11,$sp ++ lvx v25,r11,$sp + addi r11,r11,32 +- lvx v27,r10,$sp ++ lvx v26,r10,$sp + addi r10,r10,32 +- lvx v28,r11,$sp ++ lvx v27,r11,$sp + addi r11,r11,32 +- lvx v29,r10,$sp ++ lvx v28,r10,$sp + addi r10,r10,32 +- lvx v30,r11,$sp +- lvx v31,r10,$sp ++ lvx v29,r11,$sp ++ addi r11,r11,32 ++ lvx v30,r10,$sp ++ lvx v31,r11,$sp + $POP r27,`$VSXFRAME-$SIZE_T*5`($sp) + $POP r28,`$VSXFRAME-$SIZE_T*4`($sp) + $POP r29,`$VSXFRAME-$SIZE_T*3`($sp)