Skip to content

Commit f9cf66a

Browse files
Patch gdb for CVE-2025-11082
1 parent 6a21314 commit f9cf66a

File tree

2 files changed

+52
-1
lines changed

2 files changed

+52
-1
lines changed

SPECS/gdb/CVE-2025-11082.patch

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
From 673292b3f4800cbf9b454513b5e535809e46d1fc Mon Sep 17 00:00:00 2001
2+
From: "H.J. Lu" <[email protected]>
3+
Date: Mon, 22 Sep 2025 15:20:34 +0800
4+
Subject: [PATCH] elf: Don't read beyond .eh_frame section size
5+
6+
PR ld/33464
7+
* elf-eh-frame.c (_bfd_elf_parse_eh_frame): Don't read beyond
8+
.eh_frame section size.
9+
10+
Signed-off-by: H.J. Lu <[email protected]>
11+
Signed-off-by: Azure Linux Security Servicing Account <[email protected]>
12+
Upstream-reference: https://github.com/bminor/binutils-gdb/commit/ea1a0737c7692737a644af0486b71e4a392cbca8.patch
13+
---
14+
bfd/elf-eh-frame.c | 8 ++++++--
15+
1 file changed, 6 insertions(+), 2 deletions(-)
16+
17+
diff --git a/bfd/elf-eh-frame.c b/bfd/elf-eh-frame.c
18+
index 6ce6d22..f1f6b46 100644
19+
--- a/bfd/elf-eh-frame.c
20+
+++ b/bfd/elf-eh-frame.c
21+
@@ -733,6 +733,7 @@ _bfd_elf_parse_eh_frame (bfd *abfd, struct bfd_link_info *info,
22+
if (hdr_id == 0)
23+
{
24+
unsigned int initial_insn_length;
25+
+ char *null_byte;
26+
27+
/* CIE */
28+
this_inf->cie = 1;
29+
@@ -749,10 +750,13 @@ _bfd_elf_parse_eh_frame (bfd *abfd, struct bfd_link_info *info,
30+
REQUIRE (cie->version == 1
31+
|| cie->version == 3
32+
|| cie->version == 4);
33+
- REQUIRE (strlen ((char *) buf) < sizeof (cie->augmentation));
34+
+ null_byte = memchr ((char *) buf, 0, end - buf);
35+
+ REQUIRE (null_byte != NULL);
36+
+ REQUIRE ((size_t) (null_byte - (char *) buf)
37+
+ < sizeof (cie->augmentation));
38+
39+
strcpy (cie->augmentation, (char *) buf);
40+
- buf = (bfd_byte *) strchr ((char *) buf, '\0') + 1;
41+
+ buf = (bfd_byte *) null_byte + 1;
42+
this_inf->u.cie.aug_str_len = buf - start - 1;
43+
ENSURE_NO_RELOCS (buf);
44+
if (buf[0] == 'e' && buf[1] == 'h')
45+
--
46+
2.45.4
47+

SPECS/gdb/gdb.spec

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Summary: C debugger
22
Name: gdb
33
Version: 11.2
4-
Release: 7%{?dist}
4+
Release: 8%{?dist}
55
License: GPLv2+
66
Vendor: Microsoft Corporation
77
Distribution: Mariner
@@ -18,6 +18,7 @@ Patch6: CVE-2022-48065.patch
1818
Patch7: CVE-2022-47673.patch
1919
Patch8: CVE-2022-47696.patch
2020
Patch9: CVE-2025-7546.patch
21+
Patch10: CVE-2025-11082.patch
2122
BuildRequires: expat-devel
2223
BuildRequires: gcc-c++
2324
BuildRequires: gcc-gfortran
@@ -102,6 +103,9 @@ rm -rvf libctf/testsuite
102103
%{_mandir}/*/*
103104

104105
%changelog
106+
* Fri Oct 03 2025 Azure Linux Security Servicing Account <[email protected]> - 11.2-8
107+
- Patch for CVE-2025-11082
108+
105109
* Fri Jul 18 2025 Akhila Guruju <[email protected]> - 11.2-7
106110
- Patch CVE-2025-7546
107111
- Fix package tests

0 commit comments

Comments
 (0)