Skip to contentSkip to conversation

binutils: Fix CVE-2022-44840

PATCH New [email protected] 1 participant 2 messages Oct 11, 2023

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 binutils: Fix CVE-2022-44840

From: Yash Shinde <[email protected]>

---
 .../binutils/binutils-2.38.inc                |   1 +
 .../binutils/0030-CVE-2022-44840.patch        | 151 ++++++++++++++++++
 2 files changed, 152 insertions(+)
 create mode 100644 meta/recipes-devtools/binutils/binutils/0030-CVE-2022-44840.patch
meta/recipes-devtools/binutils/binutils-2.38.inc +1 -0
index 638b1ba93d..7c5d8f79ec 100644
@@ -59,5 +59,6 @@ SRC_URI = "\
      file://0029-CVE-2022-48065-1.patch \
      file://0029-CVE-2022-48065-2.patch \
      file://0029-CVE-2022-48065-3.patch \
+     file://0030-CVE-2022-44840.patch \
 "
 S  = "${WORKDIR}/git"
meta/recipes-devtools/binutils/binutils/0030-CVE-2022-44840.patch new file +151 -0

151 lines not on this page · raw message

Signature · 1 line
2.39.0
#1 lore raw

PATCH 2/2 binutils: Fix CVE-2022-45703

From: Yash Shinde <[email protected]>

---
 .../binutils/binutils-2.38.inc                |   2 +
 .../binutils/0031-CVE-2022-45703-1.patch      | 147 ++++++++++++++++++
 .../binutils/0031-CVE-2022-45703-2.patch      |  31 ++++
 3 files changed, 180 insertions(+)
 create mode 100644 meta/recipes-devtools/binutils/binutils/0031-CVE-2022-45703-1.patch
 create mode 100644 meta/recipes-devtools/binutils/binutils/0031-CVE-2022-45703-2.patch
meta/recipes-devtools/binutils/binutils-2.38.inc +2 -0
index 7c5d8f79ec..0964ab0825 100644
@@ -60,5 +60,7 @@ SRC_URI = "\
      file://0029-CVE-2022-48065-2.patch \
      file://0029-CVE-2022-48065-3.patch \
      file://0030-CVE-2022-44840.patch \
+     file://0031-CVE-2022-45703-1.patch \
+     file://0031-CVE-2022-45703-2.patch \
 "
 S  = "${WORKDIR}/git"
meta/recipes-devtools/binutils/binutils/0031-CVE-2022-45703-1.patch new file +147 -0

147 lines not on this page · raw message

meta/recipes-devtools/binutils/binutils/0031-CVE-2022-45703-2.patch new file +31 -0
new file mode 100644
index 0000000000..1fac9739dd
@@ -0,0 +1,31 @@
+From 69bfd1759db41c8d369f9dcc98a135c5a5d97299 Mon Sep 17 00:00:00 2001
+From: Alan Modra <[email protected]>
+Date: Fri, 18 Nov 2022 11:29:13 +1030
+Subject: [PATCH] PR29799 heap buffer overflow in display_gdb_index
+ dwarf.c:10548
+
+	PR 29799
+	* dwarf.c (display_gdb_index): Typo fix.
+Upstream-Status: Backport [https://sourceware.org/git/?p=binutils-gdb.git;a=blobdiff_plain;f=binutils/dwarf.c;h=4bba8dfb81a6df49f5e61b3fae99dd545cc5c7dd;hp=7730293326ac1049451eb4a037ac86d827030700;hb=69bfd1759db41c8d369f9dcc98a135c5a5d97299;hpb=7828dfa93b210b6bbc6596e6e096cc150a9f8aa4]
+
+CVE: CVE-2022-45703
+
+Signed-off-by: yash shinde <[email protected]>
+
+---
+ binutils/dwarf.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/binutils/dwarf.c b/binutils/dwarf.c
+index 7730293326a..4bba8dfb81a 100644
+--- a/binutils/dwarf.c
++++ b/binutils/dwarf.c
+@@ -10562,7 +10562,7 @@ display_gdb_index (struct dwarf_section
+     {
+       uint64_t low = byte_get_little_endian (address_table + i * 20, 8);
+       uint64_t high = byte_get_little_endian (address_table + i * 20 + 8, 8);
+-      uint32_t cu_index = byte_get_little_endian (address_table + i + 20 + 16, 4);
++      uint32_t cu_index = byte_get_little_endian (address_table + i * 20 + 16, 4);
+ 
+       print_dwarf_vma (low, 8);
+       print_dwarf_vma (high, 8);
Signature · 1 line
2.39.0