libdw, readelf: Make sure there is enough data to read full aranges header.
authorMark Wielaard <mark@klomp.org>
Sat, 18 Aug 2018 11:27:48 +0000 (13:27 +0200)
committerMark Wielaard <mark@klomp.org>
Sat, 18 Aug 2018 11:27:48 +0000 (13:27 +0200)
commit29e31978ba51c1051743a503ee325b5ebc03d7e9
tree7bc138fc91e3ef04a04406a1426ab8cef33b2628
parentc9f90a70900e753dde15cc9348dcf7de08b031eb
libdw, readelf: Make sure there is enough data to read full aranges header.

dwarf_getaranges didn't check if there was enough data left to read both
the address and segment size. readelf didn't check there was enough data
left to read the segment size.

https://sourceware.org/bugzilla/show_bug.cgi?id=23541

Signed-off-by: Mark Wielaard <mark@klomp.org>
libdw/ChangeLog
libdw/dwarf_getaranges.c
src/ChangeLog
src/readelf.c