diff options
author | Alan Modra <amodra@gmail.com> | 2017-10-18 12:05:39 +1030 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2017-10-18 12:50:45 +1030 |
commit | 5396a86e439653fb5cd714b955708250777a32e5 (patch) | |
tree | 9dea822354c79ab221d79573a7269553ffe8b4d2 /gdb/solib-darwin.h | |
parent | b7213666d6035713c3a2786ee418085e07cb3cca (diff) | |
download | gdb-5396a86e439653fb5cd714b955708250777a32e5.zip gdb-5396a86e439653fb5cd714b955708250777a32e5.tar.gz gdb-5396a86e439653fb5cd714b955708250777a32e5.tar.bz2 |
PR22303, print_core_note out of bounds read
The print_core_note change here fixes the PR, the rest is making
readelf a little more bombproof against maliciously crafted binaries.
PR 22303
* readelf.c (print_core_note): Ensure "count" sanity check
calculation doesn't overflow.
(process_notes_at): Perform note namesz and descsz checks
using unsigned comparisons against data remaining. Catch
alignment overflow of namesz and descsz too. Don't allocate a
temp for terminating "name" when there is space available
before descdata.
Diffstat (limited to 'gdb/solib-darwin.h')
0 files changed, 0 insertions, 0 deletions