summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/binutils/binutils/CVE-2018-17360.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/binutils/binutils/CVE-2018-17360.patch')
-rw-r--r--meta/recipes-devtools/binutils/binutils/CVE-2018-17360.patch24
1 files changed, 2 insertions, 22 deletions
diff --git a/meta/recipes-devtools/binutils/binutils/CVE-2018-17360.patch b/meta/recipes-devtools/binutils/binutils/CVE-2018-17360.patch
index cef10a7546..45c637967b 100644
--- a/meta/recipes-devtools/binutils/binutils/CVE-2018-17360.patch
+++ b/meta/recipes-devtools/binutils/binutils/CVE-2018-17360.patch
@@ -15,27 +15,9 @@ Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com>
15 bfd/peXXigen.c | 11 ++++++----- 15 bfd/peXXigen.c | 11 ++++++-----
16 2 files changed, 12 insertions(+), 5 deletions(-) 16 2 files changed, 12 insertions(+), 5 deletions(-)
17 17
18diff --git a/bfd/ChangeLog b/bfd/ChangeLog
19index fef5479..81b9e56 100644
20--- a/bfd/ChangeLog
21+++ b/bfd/ChangeLog
22@@ -1,5 +1,11 @@
23 2018-09-20 Alan Modra <amodra@gmail.com>
24
25+ PR 23685
26+ * peXXigen.c (pe_print_edata): Correct export address table
27+ overflow checks. Check dataoff against section size too.
28+
29+2018-09-20 Alan Modra <amodra@gmail.com>
30+
31 PR 23686
32 * dwarf2.c (read_section): Error when attempting to malloc
33 "(bfd_size_type) -1".
34diff --git a/bfd/peXXigen.c b/bfd/peXXigen.c
35index 598f2ca..1645ef4 100644
36--- a/bfd/peXXigen.c 18--- a/bfd/peXXigen.c
37+++ b/bfd/peXXigen.c 19+++ b/bfd/peXXigen.c
38@@ -1661,7 +1661,8 @@ pe_print_edata (bfd * abfd, void * vfile) 20@@ -1661,7 +1661,8 @@ pe_print_edata (bfd * abfd, void * vfile
39 21
40 dataoff = addr - section->vma; 22 dataoff = addr - section->vma;
41 datasize = extra->DataDirectory[PE_EXPORT_TABLE].Size; 23 datasize = extra->DataDirectory[PE_EXPORT_TABLE].Size;
@@ -45,7 +27,7 @@ index 598f2ca..1645ef4 100644
45 { 27 {
46 fprintf (file, 28 fprintf (file,
47 _("\nThere is an export table in %s, but it does not fit into that section\n"), 29 _("\nThere is an export table in %s, but it does not fit into that section\n"),
48@@ -1778,11 +1779,11 @@ pe_print_edata (bfd * abfd, void * vfile) 30@@ -1778,11 +1779,11 @@ pe_print_edata (bfd * abfd, void * vfile
49 edt.base); 31 edt.base);
50 32
51 /* PR 17512: Handle corrupt PE binaries. */ 33 /* PR 17512: Handle corrupt PE binaries. */
@@ -61,5 +43,3 @@ index 598f2ca..1645ef4 100644
61 fprintf (file, _("\tInvalid Export Address Table rva (0x%lx) or entry count (0x%lx)\n"), 43 fprintf (file, _("\tInvalid Export Address Table rva (0x%lx) or entry count (0x%lx)\n"),
62 (long) edt.eat_addr, 44 (long) edt.eat_addr,
63 (long) edt.num_functions); 45 (long) edt.num_functions);
64--
652.9.3