summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools
diff options
context:
space:
mode:
authorArchana Polampalli <archana.polampalli@windriver.com>2025-11-28 21:37:57 +0530
committerSteve Sakoman <steve@sakoman.com>2025-12-05 06:56:34 -0800
commit5f8155aefa0930c0495f24cfc2dbecc8b6ff4e0d (patch)
tree2733123ca5c841e92157ca68fb5831932c5576e4 /meta/recipes-devtools
parentdd0a2c24702152c76547b1db2690ff5af3d23f06 (diff)
downloadpoky-5f8155aefa0930c0495f24cfc2dbecc8b6ff4e0d.tar.gz
go: fix CVE-2025-58189
When Conn.Handshake fails during ALPN negotiation the error contains attacker controlled information (the ALPN protocols sent by the client) which is not escaped. (From OE-Core rev: b3f055df67cf345c9a17c5c1c874c778d538ba9e) Signed-off-by: Archana Polampalli <archana.polampalli@windriver.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
Diffstat (limited to 'meta/recipes-devtools')
-rw-r--r--meta/recipes-devtools/go/go-1.17.13.inc1
-rw-r--r--meta/recipes-devtools/go/go-1.18/CVE-2025-58189.patch51
2 files changed, 52 insertions, 0 deletions
diff --git a/meta/recipes-devtools/go/go-1.17.13.inc b/meta/recipes-devtools/go/go-1.17.13.inc
index c5aa3f9786..61fee12cf9 100644
--- a/meta/recipes-devtools/go/go-1.17.13.inc
+++ b/meta/recipes-devtools/go/go-1.17.13.inc
@@ -70,6 +70,7 @@ SRC_URI = "https://golang.org/dl/go${PV}.src.tar.gz;name=main \
70 file://CVE-2025-47906.patch \ 70 file://CVE-2025-47906.patch \
71 file://CVE-2024-24783.patch \ 71 file://CVE-2024-24783.patch \
72 file://CVE-2025-58187.patch \ 72 file://CVE-2025-58187.patch \
73 file://CVE-2025-58189.patch \
73 " 74 "
74SRC_URI[main.sha256sum] = "a1a48b23afb206f95e7bbaa9b898d965f90826f6f1d1fc0c1d784ada0cd300fd" 75SRC_URI[main.sha256sum] = "a1a48b23afb206f95e7bbaa9b898d965f90826f6f1d1fc0c1d784ada0cd300fd"
75 76
diff --git a/meta/recipes-devtools/go/go-1.18/CVE-2025-58189.patch b/meta/recipes-devtools/go/go-1.18/CVE-2025-58189.patch
new file mode 100644
index 0000000000..835f071733
--- /dev/null
+++ b/meta/recipes-devtools/go/go-1.18/CVE-2025-58189.patch
@@ -0,0 +1,51 @@
1From 2e1e356e33b9c792a9643749a7626a1789197bb9 Mon Sep 17 00:00:00 2001
2From: Roland Shoemaker <roland@golang.org>
3Date: Mon, 29 Sep 2025 10:11:56 -0700
4Subject: [PATCH] crypto/tls: quote protocols in ALPN error message
5
6Quote the protocols sent by the client when returning the ALPN
7negotiation error message.
8
9Fixes CVE-2025-58189
10Updates #75652
11Fixes #75660
12
13Change-Id: Ie7b3a1ed0b6efcc1705b71f0f1e8417126661330
14Reviewed-on: https://go-review.googlesource.com/c/go/+/707776
15Auto-Submit: Roland Shoemaker <roland@golang.org>
16Reviewed-by: Neal Patel <nealpatel@google.com>
17Reviewed-by: Nicholas Husin <nsh@golang.org>
18Auto-Submit: Nicholas Husin <nsh@golang.org>
19Reviewed-by: Nicholas Husin <husin@google.com>
20TryBot-Bypass: Roland Shoemaker <roland@golang.org>
21Reviewed-by: Daniel McCarney <daniel@binaryparadox.net>
22(cherry picked from commit 4e9006a716533fe1c7ee08df02dfc73078f7dc19)
23Reviewed-on: https://go-review.googlesource.com/c/go/+/708096
24LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
25Reviewed-by: Carlos Amedee <carlos@golang.org>
26
27CVE: CVE-2025-58189
28
29Upstream-Status: Backport [https://github.com/golang/go/commit/2e1e356e33b9c792a9643749a7626a1789197bb9]
30
31Signed-off-by: Archana Polampalli <archana.polampalli@windriver.com>
32---
33 src/crypto/tls/handshake_server.go | 2 +-
34 1 file changed, 1 insertion(+), 1 deletion(-)
35
36diff --git a/src/crypto/tls/handshake_server.go b/src/crypto/tls/handshake_server.go
37index 4e84aa9..17b6891 100644
38--- a/src/crypto/tls/handshake_server.go
39+++ b/src/crypto/tls/handshake_server.go
40@@ -312,7 +312,7 @@ func negotiateALPN(serverProtos, clientProtos []string, quic bool) (string, erro
41 if http11fallback {
42 return "", nil
43 }
44- return "", fmt.Errorf("tls: client requested unsupported application protocols (%s)", clientProtos)
45+ return "", fmt.Errorf("tls: client requested unsupported application protocols (%q)", clientProtos)
46 }
47
48 // supportsECDHE returns whether ECDHE key exchanges can be used with this
49--
502.40.0
51