Skip to content

Commit 76c1706

Browse files
authored
[LOW] Patch nodejs18 for CVE-2025-5889 (#14065)
1 parent f301784 commit 76c1706

2 files changed

Lines changed: 30 additions & 2 deletions

File tree

SPECS/nodejs/CVE-2025-5889.patch

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
From 5ac97cd987e7dcc2d5ccd0803eb184a7954b2176 Mon Sep 17 00:00:00 2001
2+
From: Aninda <v-anipradhan@microsoft.com>
3+
Date: Sat, 21 Jun 2025 07:40:51 -0400
4+
Subject: [PATCH] Address CVE-2025-5889
5+
Upstream Patch Reference: https://github.com/juliangruber/brace-expansion/pull/65/commits/a5b98a4f30d7813266b221435e1eaaf25a1b0ac5
6+
---
7+
deps/minimatch/src/node_modules/brace-expansion/index.js | 2 +-
8+
1 file changed, 1 insertion(+), 1 deletion(-)
9+
10+
diff --git a/deps/minimatch/src/node_modules/brace-expansion/index.js b/deps/minimatch/src/node_modules/brace-expansion/index.js
11+
index 4af9ddee..a27f81ce 100644
12+
--- a/deps/minimatch/src/node_modules/brace-expansion/index.js
13+
+++ b/deps/minimatch/src/node_modules/brace-expansion/index.js
14+
@@ -116,7 +116,7 @@ function expand(str, isTop) {
15+
var isOptions = m.body.indexOf(',') >= 0;
16+
if (!isSequence && !isOptions) {
17+
// {a},b}
18+
- if (m.post.match(/,.*\}/)) {
19+
+ if (m.post.match(/,(?!,).*\}/)) {
20+
str = m.pre + '{' + m.body + escClose + m.post;
21+
return expand(str);
22+
}
23+
--
24+
2.34.1
25+

SPECS/nodejs/nodejs18.spec

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Name: nodejs18
66
# WARNINGS: MUST check and update the 'npm_version' macro for every version update of this package.
77
# The version of NPM can be found inside the sources under 'deps/npm/package.json'.
88
Version: 18.20.3
9-
Release: 8%{?dist}
9+
Release: 9%{?dist}
1010
License: BSD and MIT and Public Domain and NAIST-2003 and Artistic-2.0
1111
Group: Applications/System
1212
Vendor: Microsoft Corporation
@@ -27,7 +27,7 @@ Patch7: CVE-2025-27516.patch
2727
Patch8: CVE-2025-47279.patch
2828
Patch9: CVE-2025-23166.patch
2929
Patch10: CVE-2025-7656.patch
30-
30+
Patch11: CVE-2025-5889.patch
3131
BuildRequires: brotli-devel
3232
BuildRequires: coreutils >= 8.22
3333
BuildRequires: gcc
@@ -128,6 +128,9 @@ make cctest
128128
%{_datadir}/systemtap/tapset/node.stp
129129

130130
%changelog
131+
* Mon Aug 04 2025 Aninda Pradhan <v-anipradhan@microsoft.com> - 18.20.3-9
132+
- Patch CVE-2025-5889
133+
131134
* Mon Jul 21 2025 Kevin Lockwood <v-klockwood@microsoft.com> - 18.20.3-8
132135
- Patch CVE-2025-7656
133136

0 commit comments

Comments
 (0)