Skip to content

Commit b6972e1

Browse files
azurelinux-securityKanishk Bansaljykanase
authored
[AutoPR- Security] Patch binutils for CVE-2025-8225 [MEDIUM] (microsoft#14406)
Signed-off-by: Kanishk Bansal <kanbansal@microsoft.com> Co-authored-by: Kanishk Bansal <kanbansal@microsoft.com> Co-authored-by: jykanase <v-jykanase@microsoft.com>
1 parent e84b714 commit b6972e1

File tree

7 files changed

+54
-15
lines changed

7 files changed

+54
-15
lines changed

SPECS/binutils/CVE-2025-8225.patch

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
From 6c3dde2579de7010c77abc23d2b2234f5a9a4aeb Mon Sep 17 00:00:00 2001
2+
From: Azure Linux Security Servicing Account
3+
<azurelinux-security@microsoft.com>
4+
Date: Mon, 28 Jul 2025 18:45:41 +0000
5+
Subject: [PATCH] Fix CVE CVE-2025-8225 in binutils
6+
7+
Upstream Patch Reference: https://gitlab.com/gnutools/binutils-gdb/-/commit/e51fdff7d2e538c0e5accdd65649ac68e6e0ddd4.patch
8+
---
9+
binutils/dwarf.c | 8 +++-----
10+
1 file changed, 3 insertions(+), 5 deletions(-)
11+
12+
diff --git a/binutils/dwarf.c b/binutils/dwarf.c
13+
index 4f695bf2..ea83e35a 100644
14+
--- a/binutils/dwarf.c
15+
+++ b/binutils/dwarf.c
16+
@@ -3625,13 +3625,11 @@ process_debug_info (struct dwarf_section * section,
17+
}
18+
19+
if ((do_loc || do_debug_loc || do_debug_ranges || do_debug_info)
20+
- && num_debug_info_entries == 0
21+
- && ! do_types)
22+
+ && alloc_num_debug_info_entries == 0
23+
+ && !do_types)
24+
{
25+
-
26+
/* Then allocate an array to hold the information. */
27+
- debug_information = (debug_info *) cmalloc (num_units,
28+
- sizeof (* debug_information));
29+
+ debug_information = cmalloc (num_units, sizeof (*debug_information));
30+
if (debug_information == NULL)
31+
{
32+
error (_("Not enough memory for a debug info array of %u entries\n"),
33+
--
34+
2.45.4
35+

SPECS/binutils/binutils.spec

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,13 @@
2121
Summary: Contains a linker, an assembler, and other tools
2222
Name: binutils
2323
Version: 2.41
24-
Release: 7%{?dist}
24+
Release: 8%{?dist}
2525
License: GPLv2+
2626
Vendor: Microsoft Corporation
2727
Distribution: Azure Linux
2828
Group: System Environment/Base
2929
URL: https://www.gnu.org/software/binutils
30-
Source0: https://ftp.gnu.org/gnu/binutils/%{name}-%{version}.tar.xz
30+
Source0: https://sourceware.org/pub/binutils/releases/%{name}-%{version}.tar.xz
3131
# Patch was derived from source: https://src.fedoraproject.org/rpms/binutils/blob/f34/f/binutils-export-demangle.h.patch
3232
Patch0: export-demangle-header.patch
3333
# The gold linker doesn't understand the 'module_info.ld' script passed to all linkers and the tests fail to correctly link.
@@ -42,6 +42,7 @@ Patch8: CVE-2025-5245.patch
4242
Patch9: CVE-2025-5244.patch
4343
Patch10: CVE-2025-7546.patch
4444
Patch11: CVE-2025-7545.patch
45+
Patch12: CVE-2025-8225.patch
4546
Provides: bundled(libiberty)
4647

4748
# Moving macro before the "SourceX" tags breaks PR checks parsing the specs.
@@ -331,6 +332,9 @@ find %{buildroot} -type f -name "*.la" -delete -print
331332
%do_files aarch64-linux-gnu %{build_aarch64}
332333

333334
%changelog
335+
* Mon Jul 28 2025 Azure Linux Security Servicing Account <azurelinux-security@microsoft.com> - 2.41-8
336+
- Patch for CVE-2025-8225
337+
334338
* Thu Jul 17 2025 Azure Linux Security Servicing Account <azurelinux-security@microsoft.com> - 2.41-7
335339
- Patch for CVE-2025-7546, CVE-2025-7545
336340

cgmanifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1128,7 +1128,7 @@
11281128
"other": {
11291129
"name": "binutils",
11301130
"version": "2.41",
1131-
"downloadUrl": "https://ftp.gnu.org/gnu/binutils/binutils-2.41.tar.xz"
1131+
"downloadUrl": "https://sourceware.org/pub/binutils/releases/binutils-2.41.tar.xz"
11321132
}
11331133
}
11341134
},

toolkit/resources/manifests/package/pkggen_core_aarch64.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ zlib-devel-1.3.1-1.azl3.aarch64.rpm
1313
file-5.45-1.azl3.aarch64.rpm
1414
file-devel-5.45-1.azl3.aarch64.rpm
1515
file-libs-5.45-1.azl3.aarch64.rpm
16-
binutils-2.41-7.azl3.aarch64.rpm
17-
binutils-devel-2.41-7.azl3.aarch64.rpm
16+
binutils-2.41-8.azl3.aarch64.rpm
17+
binutils-devel-2.41-8.azl3.aarch64.rpm
1818
gmp-6.3.0-1.azl3.aarch64.rpm
1919
gmp-devel-6.3.0-1.azl3.aarch64.rpm
2020
mpfr-4.2.1-1.azl3.aarch64.rpm

toolkit/resources/manifests/package/pkggen_core_x86_64.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ zlib-devel-1.3.1-1.azl3.x86_64.rpm
1313
file-5.45-1.azl3.x86_64.rpm
1414
file-devel-5.45-1.azl3.x86_64.rpm
1515
file-libs-5.45-1.azl3.x86_64.rpm
16-
binutils-2.41-7.azl3.x86_64.rpm
17-
binutils-devel-2.41-7.azl3.x86_64.rpm
16+
binutils-2.41-8.azl3.x86_64.rpm
17+
binutils-devel-2.41-8.azl3.x86_64.rpm
1818
gmp-6.3.0-1.azl3.x86_64.rpm
1919
gmp-devel-6.3.0-1.azl3.x86_64.rpm
2020
mpfr-4.2.1-1.azl3.x86_64.rpm

toolkit/resources/manifests/package/toolchain_aarch64.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@ bash-5.2.15-3.azl3.aarch64.rpm
3030
bash-debuginfo-5.2.15-3.azl3.aarch64.rpm
3131
bash-devel-5.2.15-3.azl3.aarch64.rpm
3232
bash-lang-5.2.15-3.azl3.aarch64.rpm
33-
binutils-2.41-7.azl3.aarch64.rpm
34-
binutils-debuginfo-2.41-7.azl3.aarch64.rpm
35-
binutils-devel-2.41-7.azl3.aarch64.rpm
33+
binutils-2.41-8.azl3.aarch64.rpm
34+
binutils-debuginfo-2.41-8.azl3.aarch64.rpm
35+
binutils-devel-2.41-8.azl3.aarch64.rpm
3636
bison-3.8.2-1.azl3.aarch64.rpm
3737
bison-debuginfo-3.8.2-1.azl3.aarch64.rpm
3838
bzip2-1.0.8-1.azl3.aarch64.rpm

toolkit/resources/manifests/package/toolchain_x86_64.txt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,10 @@ bash-5.2.15-3.azl3.x86_64.rpm
3232
bash-debuginfo-5.2.15-3.azl3.x86_64.rpm
3333
bash-devel-5.2.15-3.azl3.x86_64.rpm
3434
bash-lang-5.2.15-3.azl3.x86_64.rpm
35-
binutils-2.41-7.azl3.x86_64.rpm
36-
binutils-aarch64-linux-gnu-2.41-7.azl3.x86_64.rpm
37-
binutils-debuginfo-2.41-7.azl3.x86_64.rpm
38-
binutils-devel-2.41-7.azl3.x86_64.rpm
35+
binutils-2.41-8.azl3.x86_64.rpm
36+
binutils-aarch64-linux-gnu-2.41-8.azl3.x86_64.rpm
37+
binutils-debuginfo-2.41-8.azl3.x86_64.rpm
38+
binutils-devel-2.41-8.azl3.x86_64.rpm
3939
bison-3.8.2-1.azl3.x86_64.rpm
4040
bison-debuginfo-3.8.2-1.azl3.x86_64.rpm
4141
bzip2-1.0.8-1.azl3.x86_64.rpm
@@ -70,7 +70,7 @@ cracklib-lang-2.9.11-1.azl3.x86_64.rpm
7070
createrepo_c-1.0.3-1.azl3.x86_64.rpm
7171
createrepo_c-debuginfo-1.0.3-1.azl3.x86_64.rpm
7272
createrepo_c-devel-1.0.3-1.azl3.x86_64.rpm
73-
cross-binutils-common-2.41-7.azl3.noarch.rpm
73+
cross-binutils-common-2.41-8.azl3.noarch.rpm
7474
cross-gcc-common-13.2.0-7.azl3.noarch.rpm
7575
curl-8.11.1-3.azl3.x86_64.rpm
7676
curl-debuginfo-8.11.1-3.azl3.x86_64.rpm

0 commit comments

Comments
 (0)