Age | Commit message (Collapse) | Author | |
---|---|---|---|
2016-08-23 | Implement support for DT_INIT_ARRAY, DT_FINI_ARRAY and DT_PREINIT_ARRAY. | Mark Kettenis | |
Don't skip DT_INIT and DT_FINI for the main executable. This matches what Linux and Solaris do. ok guenther@ | |||
2016-08-22 | This code served us well for many years, | Ingo Schwarze | |
but we are unlikely to reactivate it; espie@ agrees. The new code is in /usr/src/usr.bin/mandoc/mandocdb.c. | |||
2016-08-16 | fread hasn't taken a char * in about 900 years | Ted Unangst | |
2016-08-16 | remove unneeded casts | Ted Unangst | |
2016-08-15 | Drop -z nocombreloc. It was a rev 1.1 commit like on arm, so not clear | Philip Guenther | |
why it was needed then; perhaps fixed by the bump in binutils? Removing it enables the full relro layout for ld.so. | |||
2016-08-14 | When upcasting to off_t for multiplication, the cast needs to be *before* | Philip Guenther | |
the multiplication to avoid truncation/overflow ok krw@ | |||
2016-08-14 | Convert %q to %ll with long long casts for printf() | Philip Guenther | |
Delete pointless casts to off_t, void*, and uid_t ok krw@ | |||
2016-08-14 | Drop -z nocombreloc. That's a rev 1.1 commit so not clear why it was needed | Philip Guenther | |
then; perhaps fixed by the bump in binutils? Anyway, builds seem good without it and that enables the full relro layout for ld.so. ok kettenis@ | |||
2016-08-14 | Mark the relro/got section as read-only before setting up the environment | Philip Guenther | |
to minimize the amount of code run without it RO. | |||
2016-08-13 | Passing in &_DYNAMIC appears to have stuck, so eliminate the extra | Philip Guenther | |
variable | |||
2016-08-12 | the slimmed down random functions inside ld.so are strict clones of the | Theo de Raadt | |
libc arc4random API, so call them _dl_{arc4random,arcrandombuf} ok tedu guenther | |||
2016-08-09 | Teach arm to pass &_DYNAMIC to _dl_boot_bind(); can optimize later in tree | Philip Guenther | |
2016-08-08 | Look for a PT_GNU_RELRO section per object and, if present, mprotect that | Philip Guenther | |
range instead of the [__got_start, __got_end) range. On many archs this will cover _DYNAMIC too, so move up the DT_DEBUG handling to before relocations and the mprotect are done. ok kettenis@ | |||
2016-08-07 | As with csu, alpha passes &_DYNAMIC to _reloc_alpha_got(), so just | Philip Guenther | |
save that and pass it to _dl_boot_bind() too | |||
2016-08-07 | Teach i386 to pass &_DYNAMIC to _dl_boot_bind() | Philip Guenther | |
2016-08-07 | Teach mips64 to pass &_DYNAMIC to _dl_boot_bind() | Philip Guenther | |
mips64be testing by deraadt@ | |||
2016-08-07 | hahahah: amd64 has been passing &_DYNAMIC to _dl_boot_bind() for | Philip Guenther | |
*149 months* | |||
2016-08-07 | Flip the #ifdef logic: amd64, arm, i386, and mips64 are the only archs | Philip Guenther | |
using the #else case | |||
2016-08-05 | use a larger chunk for getentropy() and save some for next time. | Ted Unangst | |
coalesces some syscalls instead of one per random number. ok deraadt | |||
2016-08-01 | zap unused var | Jeremie Courreges-Anglas | |
2016-07-18 | Polish: | Philip Guenther | |
- copy #define workaround from mips64 to avoid dangling __CERROR symbol - remove trap DL_SYSCALL2_NOERR() macro with comment explanation - make DL_SYSCALL2() self-contained - add END() and ENTRY() macros to make the symbol table shine ok miod@ | |||
2016-07-18 | Updated advice^Wcode from miod@ for passing &_DYNAMIC to _dl_boot_bind | Philip Guenther | |
ok aoyama@ | |||
2016-07-15 | Switch m88k to pass &_DYNAMIC to _dl_boot_bind() | Philip Guenther | |
probably works: this ASM pattern is already used for _dl_dtors | |||
2016-07-13 | Adjust existing tls_config_set_cipher() callers for TLS cipher group | Joel Sing | |
changes - map the previous configuration to the equivalent in the new groups. This will be revisited post release. Discussed with beck@ | |||
2016-07-04 | Remove prebind support: binding to symbol table indices is too fragile | Philip Guenther | |
for our development process. ok kettenis@ deraadt@ | |||
2016-07-04 | Nuke prebind support; it's unworkable and we're never going to finish it. | Mark Kettenis | |
ok guenther@, deraadt@ | |||
2016-07-04 | The GOT has been initally mapped RW for *years*; ld.so doesn't need to | Philip Guenther | |
mprotect it to RW when filling in the references from the PLT in snaps for a week, ok deraadt@ | |||
2016-07-04 | Use fstatat() instead of crafting a filename to use with stat() | Philip Guenther | |
ok millert@ | |||
2016-06-21 | When handling DT_TEXTREL only set the mapping to READ+WRITE, ignore | Theo de Raadt | |
possible EXEC permission for the section, because the proper permission is set late, and there are no thread concerns here. Avoids W^X issues in oddball cases. ok guenther kettenis | |||
2016-06-21 | Handle textrels like other architectures do. | Theo de Raadt | |
ok kettenis guenther | |||
2016-06-18 | Make mips64 like all the others: only make mappings writable during relocation | Philip Guenther | |
if DT_TEXTREL was set on the object. If that's needed, only set the mapping to READ+WRITE to avoid W^X violation. ok kettenis@ | |||
2016-06-13 | Only need to sync the icache on the GOT for the old BSS PLT format | Philip Guenther | |
ok kettenis@ | |||
2016-06-08 | Some ELF ABIs still require a PLT that is both writable and executable. To | Mark Kettenis | |
avoid W^X violations, initially map such segments as writable and non-executable, and change the mapping to non-writable and executable after initial relocation processing. As a side-benefit this means we no longer depend on the __plt_start and __plt_end to make the PLT read-only after relocation processing. This will break binaries linked with ld -Z, most notably emacs, on some of our architectures. ok deraadt@, guenther@ | |||
2016-06-05 | Avoid W^X violation when setting DT_DEBUG on mips64. | Mark Kettenis | |
ok deraadt@ | |||
2016-05-26 | for textrels (sthen ran into one...): | Theo de Raadt | |
Ignore the listed protection (which may contain X) when making page writeable temporary. | |||
2016-05-22 | Ignore the listed protection (which may contain X) when making page | Theo de Raadt | |
writeable temporary. As pointed out by kettenis, discussed with guenther | |||
2016-05-21 | mul/div/rem replacement should happen without PROT_EXEC | Theo de Raadt | |
ok guenther | |||
2016-05-21 | Temporarily make the PLT writable when we're initializing the magic slots | Mark Kettenis | |
or doing non-lazy relocation processing. ok guenther@ | |||
2016-05-19 | Give the caller a chance to handle the failure if unable to allocate | Philip Guenther | |
the TIB for a new thread ok jca@ millert@ deraadt@ | |||
2016-05-19 | ld.so can now be entered by multiple threads via _dl_{allocate,free}_tib(), | Philip Guenther | |
so do locking in ld.so's malloc subsystem, (re)using the existing _dl_thread_kern_{stop,go}() callbacks. problem diagnosed by jsing@ in the 'go' port; fix tested there and by semarie@ in the 'rust' port | |||
2016-05-18 | fix types for mmap wrappers. A few whitespace cleanups snuck in. | Theo de Raadt | |
ok guenther | |||
2016-05-17 | tyop | Jeremie Courreges-Anglas | |
2016-05-12 | more hppa64 cleaning | Theo de Raadt | |
2016-05-11 | remove hppa64 port, which we never got going beyond broken single users. | Theo de Raadt | |
hppa reverse-stack gives us a valuable test case, but most developers don't have a 2nd one to proceed further with this. ok kettenis | |||
2016-05-07 | Move the set_tcb after getdents to keep L_cerr in range. | Philip Guenther | |
ok deraadt@ | |||
2016-05-07 | Use a Thread Information Block in both single and multi-threaded programs. | Philip Guenther | |
This stores errno, the cancelation flags, and related bits for each thread and is allocated by ld.so or libc.a. This is an ABI break from 5.9-stable! Make libpthread dlopen'able by moving the cancelation wrappers into libc and doing locking and fork/errno handling via callbacks that libpthread registers when it first initializes. 'errno' *must* be declared via <errno.h> now! Clean up libpthread's symbol exports like libc. On powerpc, offset the TIB/TCB/TLS data from the register per the ELF spec. Testing by various, particularly sthen@ and patrick@ ok kettenis@ | |||
2016-05-04 | Kill #ifdef INET6 occurrences in userland. | Jeremie Courreges-Anglas | |
Prompted by and ok millert@ (tcpdump and libpcap left untouched, the #ifdef force is too strong with those) | |||
2016-04-27 | Remove pledge(2)'s that are called before chroot(2) since in the near future | Ricardo Mestre | |
this will be forbidden. The remaining pledge(2) calls after chroot(2) are still kept. OK semarie@ "it is time now" | |||
2016-04-26 | Add missing "tty" promise to the pledge(2) call | Ricardo Mestre | |
This is needed since getpass(3) calls readpassphrase(3) which in turn tries to open(2) a tty in O_RDWR mode Problem reported by Kevin Chadwick <m8il1ists ! gmail.com> Cluebat stick provided by deraadt@, OK millert@ | |||
2016-04-25 | prefer setres{u,g}id() rather than manipulating both real and effective | Theo de Raadt | |
ids, it clarifies these are full revocation situations. ok millert |