mirror of
https://git.yoctoproject.org/poky
synced 2026-09-24 22:36:21 +02:00
binutils : Fix CVE-2023-22608
Upstream-Status: Backport [https://sourceware.org/git/?p=binutils-gdb.git;a=commitdiff;h=8af23b30edbaedf009bc9b243cd4dfa10ae1ac09] (From OE-Core rev: 3dd27bbe8c19aa358916de940453de81d3831510) Signed-off-by: Yash Shinde <Yash.Shinde@windriver.com> Signed-off-by: Steve Sakoman <steve@sakoman.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
a361fb3df9
commit
6a1554f16d
@@ -0,0 +1,32 @@
|
||||
From 4b8386a90802ed8e43eac2266f6e03c92b4462ed Mon Sep 17 00:00:00 2001
|
||||
From: Nick Clifton <nickc@redhat.com>
|
||||
Date: Fri, 23 Dec 2022 13:02:04 +0000
|
||||
Subject: [PATCH] Fix illegal memory access parsing corrupt DWARF information.
|
||||
|
||||
PR 29936
|
||||
* dwarf2.c (concat_filename): Fix check for a directory index off
|
||||
the end of the directory table.
|
||||
|
||||
Upstream-Status: Backport [https://sourceware.org/git/?p=binutils-gdb.git;a=commitdiff;h=8af23b30edbaedf009bc9b243cd4dfa10ae1ac09]
|
||||
CVE: CVE-2023-22608
|
||||
|
||||
Signed-off-by: Yash Shinde <Yash.Shinde@windriver.com>
|
||||
|
||||
---
|
||||
bfd/dwarf2.c | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/bfd/dwarf2.c b/bfd/dwarf2.c
|
||||
index b7839ad6..8b07a24c 100644
|
||||
--- a/bfd/dwarf2.c
|
||||
+++ b/bfd/dwarf2.c
|
||||
@@ -1828,7 +1828,8 @@ concat_filename (struct line_info_table *table, unsigned int file)
|
||||
|
||||
if (table->files[file].dir
|
||||
/* PR 17512: file: 0317e960. */
|
||||
- && table->files[file].dir <= table->num_dirs
|
||||
+ && table->files[file].dir
|
||||
+ <= (table->use_dir_and_file_0 ? table->num_dirs - 1 : table->num_dirs)
|
||||
/* PR 17512: file: 7f3d2e4b. */
|
||||
&& table->dirs != NULL)
|
||||
{
|
||||
Reference in New Issue
Block a user