More fixes for memory corruption when readelf processes corrupt files.
authorNick Clifton <nickc@redhat.com>
Tue, 4 Nov 2014 15:29:03 +0000 (15:29 +0000)
committerNick Clifton <nickc@redhat.com>
Tue, 4 Nov 2014 15:29:03 +0000 (15:29 +0000)
commite0a31db1b16fe0a010aa46185e4a31a08e7fd97f
treeac85af3d57080574fa73083a814459940c7c043c
parentbb0d867169d7e9743d229804106a8fbcab7f3b3f
More fixes for memory corruption when readelf processes corrupt files.

PR binutils/17531
(get_32bit_program_headers): Verify program header entry size
before reading in the program headers.
(get_64bit_program_headers): Likewise.
(get_unwind_section_word): Do nothing if no section was provided.
Fail if the offset is outside of the section.
(print_dynamic_symbol): Catch out of range symbol indicies.
(process_mips_specific): Likewise.
(process_attributes): Make sure that there is enough space left in
the section before attempting to read the length of the next
attribute.
binutils/ChangeLog
binutils/readelf.c