libdwfl: Rewrite GElf_Nhdr reading in dwfl_segment_report_module
authorMark Wielaard <mark@klomp.org>
Sun, 19 Dec 2021 20:11:13 +0000 (21:11 +0100)
committerMark Wielaard <mark@klomp.org>
Sun, 19 Dec 2021 20:11:13 +0000 (21:11 +0100)
commitd844d1575522b5ad9ada0aa3c26105230a1c1884
tree68d9ed80d85b87f8e94b720673244ec2abf7420f
parentbc14c148a6ad9b84bda428bd3bc75028515f0151
libdwfl: Rewrite GElf_Nhdr reading in dwfl_segment_report_module

Make sure that the notes filesz is not too big. Rewrite reading of the
notes to check for overflow at every step. Also limit the size of the
buildid bytes.

Signed-off-by: Mark Wielaard <mark@klomp.org>
libdwfl/ChangeLog
libdwfl/dwfl_segment_report_module.c