1. 11 5月, 2012 1 次提交
  2. 04 5月, 2012 1 次提交
    • R
      overhaul SSP support to use a real canary · 58aa5f45
      Rich Felker 提交于
      pthread structure has been adjusted to match the glibc/GCC abi for
      where the canary is stored on i386 and x86_64. it will need variants
      for other archs to provide the added security of the canary's entropy,
      but even without that it still works as well as the old "minimal" ssp
      support. eventually such changes will be made anyway, since they are
      also needed for GCC/C11 thread-local storage support (not yet
      implemented).
      
      care is taken not to attempt initializing the thread pointer unless
      the program actually uses SSP (by reference to __stack_chk_fail).
      58aa5f45
  3. 25 4月, 2012 1 次提交
    • R
      first attempt at enabling stack protector support · 60872cf9
      Rich Felker 提交于
      the code is written to pre-init the thread pointer in static linked
      programs that pull in __stack_chk_fail or dynamic-linked programs that
      lookup the symbol. no explicit canary is set; the canary will be
      whatever happens to be in the thread structure at the offset gcc
      hard-coded. this can be improved later.
      60872cf9
  4. 23 8月, 2011 1 次提交
    • R
      security hardening: ensure suid programs have valid stdin/out/err · df0b5a49
      Rich Felker 提交于
      this behavior (opening fds 0-2 for a suid program) is explicitly
      allowed (but not required) by POSIX to protect badly-written suid
      programs from clobbering files they later open.
      
      this commit does add some cost in startup code, but the availability
      of auxv and the security flag will be useful elsewhere in the future.
      in particular auxv is needed for static-linked vdso support, which is
      still waiting to be committed (sorry nik!)
      df0b5a49