aboutsummaryrefslogtreecommitdiff
path: root/kern/elf-load.c
Commit message (Collapse)AuthorAgeFilesLines
* elf-load: Respect PT_GNU_STACKSergey Bugaev2024-03-291-0/+7
| | | | | If a bootstrap ELF contains a PT_GNU_STACK phdr, take stack protection from there. Otherwise, default to VM_PROT_ALL.
* x86_64: load Elf64 bootstrap modules if ! USER32Luca Dariz2023-02-161-5/+5
| | | | | | | | | * i386/include/mach/i386/exec/elf.h: add Elf64 definitions and define common Elf structures, corresponding to 32/64 bit variants at compile time. * include/mach/exec/elf.h: add Elf64 definitions * kern/elf-load.c: use common Elf structures Message-Id: <20230216213318.2048699-2-luca@orpolo.org>
* elf-load: Avoid loading PIE binaries at address 0Samuel Thibault2020-10-071-2/+9
| | | | | | | It seems that ld.so sometimes gets into troubles and hangs at bootstrap. * kern/elf-load.c (exec_load): When x.e_type == ET_DYN || x.e_type == ET_REL, add 128MiB as loadbase.
* kern: fix the error handling in exec_loadJustus Winter2013-11-111-0/+2
| | | | | | Found using the Clang Static Analyzer. * kern/elf-load.c (exec_load): Properly propagate errors.
* Initial sourceThomas Bushnell1997-02-251-0/+88