[Bug 217610] ELF loader should have a special case for program headers with p_filesz == 0

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Sun Mar 12 13:52:05 UTC 2017


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=217610

--- Comment #6 from commit-hook at freebsd.org ---
A commit references this bug:

Author: kib
Date: Sun Mar 12 13:51:13 UTC 2017
New revision: 315157
URL: https://svnweb.freebsd.org/changeset/base/315157

Log:
  Accept linkers representation for ELF segments with zero on-disk length.

  For such segments, GNU bfd linker writes knowingly incorrect value
  into the the file offset field of the program header entry, with the
  motivation that file should not be mapped for creation of this segment
  at all.

  Relax checks for the ELF structure validity when on-disk segment
  length is zero, and explicitely set mapping length to zero for such
  segments to avoid validating rounding arithmetic.

  PR:   217610
  Reported by:  Robert Clausecker <fuz at fuz.su>
  Sponsored by: The FreeBSD Foundation
  MFC after:    1 week

Changes:
  head/sys/kern/imgact_elf.c

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list