This is the mail archive of the
gdb-testers@sourceware.org
mailing list for the GDB project.
[binutils-gdb] PR22307, Heap out of bounds read in _bfd_elf_parse_gnu_properties
- From: sergiodj+buildbot at sergiodj dot net
- To: gdb-testers at sourceware dot org
- Date: Tue, 17 Oct 2017 10:54:05 -0400
- Subject: [binutils-gdb] PR22307, Heap out of bounds read in _bfd_elf_parse_gnu_properties
- Authentication-results: sourceware.org; auth=none
*** TEST RESULTS FOR COMMIT cf54ebff3b7361989712fd9c0128a9b255578163 ***
Author: Alan Modra <amodra@gmail.com>
Branch: master
Commit: cf54ebff3b7361989712fd9c0128a9b255578163
PR22307, Heap out of bounds read in _bfd_elf_parse_gnu_properties
When adding an unbounded increment to a pointer, you can't just check
against the end of the buffer but also must check that overflow
doesn't result in "negative" pointer movement. Pointer comparisons
are signed. Better, check the increment against the space left using
an unsigned comparison.
PR 22307
* elf-properties.c (_bfd_elf_parse_gnu_properties): Compare datasz
against size left rather than comparing pointers. Reorganise loop.
- Follow-Ups:
- *** COMPILATION FAILED *** Failures on Fedora-s390x-m64, branch master *** BREAKAGE ***
- Failures on Ubuntu-AArch64-m64, branch master
- Failures on Ubuntu-AArch32-native-extended-gdbserver-m32, branch master
- *** COMPILATION FAILED *** Failures on Fedora-x86_64-m64, branch master *** BREAKAGE ***
- *** COMPILATION FAILED *** Failures on Fedora-x86_64-native-gdbserver-m32, branch master *** BREAKAGE ***
- *** COMPILATION FAILED *** Failures on Fedora-x86_64-native-gdbserver-m64, branch master *** BREAKAGE ***
- *** COMPILATION FAILED *** Failures on Fedora-x86_64-native-extended-gdbserver-m64, branch master *** BREAKAGE ***
- *** COMPILATION FAILED *** Failures on Fedora-x86_64-cc-with-index, branch master *** BREAKAGE ***
- *** COMPILATION FAILED *** Failures on Fedora-i686, branch master *** BREAKAGE ***
- *** COMPILATION FAILED *** Failures on Fedora-x86_64-m32, branch master *** BREAKAGE ***
- *** COMPILATION FAILED *** Failures on Fedora-x86_64-native-extended-gdbserver-m32, branch master *** BREAKAGE ***