[PATCH] D86422: [ELF] .note.gnu.property: error for invalid pr_datasize
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Aug 23 11:33:29 PDT 2020
MaskRay created this revision.
MaskRay added reviewers: grimar, psmith.
Herald added subscribers: llvm-commits, arichardson, emaste.
Herald added a reviewer: espindola.
Herald added a project: LLVM.
MaskRay requested review of this revision.
A n_type==NT_GNU_PROPERTY_TYPE_0 note encodes a program property.
If pr_datasize is invalid, LLD may crash
(https://github.com/ClangBuiltLinux/linux/issues/1141)
This patch adds the error checking, supports big-endian, and some tests
for invalid n_descsz.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D86422
Files:
lld/ELF/InputFiles.cpp
lld/test/ELF/gnu-property-err.s
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D86422.287266.patch
Type: text/x-patch
Size: 5362 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200823/92ffc049/attachment.bin>
More information about the llvm-commits
mailing list