Skip to content
Commit 9d30a941 authored by Asherah Connor's avatar Asherah Connor Committed by Heinrich Schuchardt
Browse files

efi_loader: don't load beyond VirtualSize



PE section table entries' SizeOfRawData must be a multiple of
FileAlignment, and thus may be rounded up and larger than their
VirtualSize.

We should not load beyond the VirtualSize, which is "the total size of
the section when loaded into memory" -- we may clobber real data at the
target in some other section, since we load sections in reverse order
and sections are usually laid out sequentially.

Signed-off-by: default avatarAsherah Connor <ashe@kivikakk.ee>
Reviewed-by: default avatarHeinrich Schuchardt <xypron.glpk@gmx.de>
parent 7c82e12c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment