From 718a1da262f440b7927b324606b3f6e72f73d1eb Mon Sep 17 00:00:00 2001 From: John Reiser Date: Mon, 10 Aug 2015 05:45:52 -0700 Subject: [PATCH] Bounds check shstrtab in PackVmlinuxBase::canPack() --- src/p_vmlinx.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/p_vmlinx.cpp b/src/p_vmlinx.cpp index d100eaf6..0dbf7571 100644 --- a/src/p_vmlinx.cpp +++ b/src/p_vmlinx.cpp @@ -165,6 +165,7 @@ bool PackVmlinuxBase::canPack() int j; for (p = shdri, j= ehdri.e_shnum; --j>=0; ++p) { if (Shdr::SHT_PROGBITS==p->sh_type + && (p->sh_name + shstrsec->sh_offset) < (unsigned)file_size && 0==strcmp("__ksymtab", p->sh_name + shstrtab)) { break; }