Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
loader: x86_64: elf: Avoid reading beyond file end
The ELF header contains offsets that the loader uses to find other structures. If those offsets are beyond the end of the file (or would go past the end of the file) it is essential to error out when attempting to read those. Using `Read::read_exact()` permits this. Signed-off-by: Bo Chen <chen.bo@intel.com> Co-authored-by: Rob Bradford <robert.bradford@intel.com>
- Loading branch information