Commit Graph

2584 Commits

Author SHA1 Message Date
skrll 3770380428 Unbreak gdb by ensuring _rtld_debug_state is in the dynamic symbol table.
mmm 1 line diffs

mmm not breaking backwards compatibility for anything known/unknown or
public/private.
2011-01-25 12:25:43 +00:00
matt 709c8a2f01 Move powerpc gotptr to the end to preserve binary compatibility. 2011-01-16 15:56:37 +00:00
matt b094d98191 Warn about DT_TEXTRELs 2011-01-16 02:36:05 +00:00
matt d31dbd7578 Add secure-plt support for powerpc to ld.elf_so. As part of this, we have to
stop calling into the GOT/_DYNAMIC since they are no longer executable.
2011-01-16 01:22:29 +00:00
christos bfd4da8575 PR/44390: Paul Koning: make code gcc-4.5.1 friendly. 2011-01-14 23:56:13 +00:00
pooka 09159e5c0a Make sure bozo_auth_check_401() isn't called with a NULL "request".
reviewed by mrg
2011-01-12 19:29:24 +00:00
plunky f302f6417c the Name for this manpage is "ld.aout_so". Use it. 2011-01-01 16:34:52 +00:00
skrll f1d73a2c94 Add support for DF_1_BIND_NOW, DF_1_NODELETE and DF_1_NOOPEN marked
objects, and the RTLD_NODELETE and RTLD_NOLOAD flags to dlopen(3).

Mark libpthread as DF_1_NOOPEN and use it to test the functionality.

Somewhat taken from FreeBSD.

Fixes PR 42029.

OK from christos and joerg.
2010-12-24 12:41:42 +00:00
mlelstv e5275d16e0 Deduce raw device correctly by prepending "r" to basename. 2010-12-23 18:08:41 +00:00
skrll 1f45aab781 Sprinkle some KNF. 2010-12-19 17:26:51 +00:00
skrll ad7786ec8b Remove unnecessary #ifdef RTLD_DEBUG 2010-12-19 17:17:50 +00:00
wiz 617acddc41 Remove superfluous Pp. 2010-12-17 08:50:26 +00:00
skrll 1ee8ff33ba Remove implementation detail.
Bump date.
2010-12-17 07:04:52 +00:00
joerg c4120e324e Replace use of errlist with a single concatenated version and an offset
array. This requires less storage and avoids one runtime relocation per
errno value.
2010-12-16 22:52:32 +00:00
joerg 67cc8c0871 Don't use normal environment handling functions from libc, but iterate
once over the array and clean out entries as needed.
2010-12-16 22:47:27 +00:00
skrll 126c589398 s/rdbg/dbg/ in a few places. 2010-12-16 19:59:39 +00:00
skrll 76d5f138f4 Remove incorrect comment. 2010-12-16 19:35:38 +00:00
wiz fbc697a1ed Note that $ORIGIN kernel support (in kern/kern_exec.c) is currently disabled.
Info from skrll@.
Bump date.
2010-12-16 19:25:41 +00:00
tls eaa351b215 When invoking a content handler specified via -C, set the REDIRECT_STATUS
CGI variable to "200".  This approximates the Apache behavior which is
required by phpcgi in PHP 5.3 (and by some compilations of older PHP
versions).

I have a revolutionary idea.  Perhaps instead of imposing bizarre
requirements on other programs in the name of "security", the PHP
developers should make their own code compile with oh, I don't know,
maybe -Wuninitialized.  That might have an effect on the security of
systems using PHP rather than on the "security" of such systems...

...excuse me, got to go now, I think my airquotes just wore out.
2010-12-14 13:27:39 +00:00
joerg 67e01e0a99 Build ld.elf_so with -fvisibility=hidden. Exploit this for i386/x86_64
to simplify the assembler code.
2010-12-05 00:56:06 +00:00
joerg 91118529e4 ANSIfy 2010-12-03 23:07:49 +00:00
joerg 239c31f883 Add comment about the unusual stack alignment in .rtld_bind_start. 2010-12-03 22:48:25 +00:00
tron 1fbd900608 Don't use internal libc function __findenv(). 2010-11-14 22:09:16 +00:00
christos acfd35dad9 PR/44010: YAMAMOTO Takashi: sbrk: grow 0xb3ba2000 failed, error = 12"
(due to setenv changes?)
Provide a mini unsetenv that does not allocate/free memory and does not
bother about locking.
2010-10-29 15:08:17 +00:00
skrll 8b916d603d Add cast so that usr.bin/ldd/elf32 builds. 2010-10-16 17:48:12 +00:00
skrll e6cdac9c4b Implement dl_iterate_phdr.
Somewhat taken from FreeBSD. Manual page from OpenBSD.
2010-10-16 10:27:06 +00:00
skrll 0a77584d8f Revert previous for now. It's part of a larger commit which will arrive
soon.
2010-10-15 15:08:05 +00:00
skrll a048346afd Be more tolerant to the location of PT_PHDR in the segment list. 2010-10-15 07:22:44 +00:00
christos 45bdf1678c restore binary compatibility for pre-2.0 binaries, requested by skrll and core. 2010-10-10 21:27:16 +00:00
skrll a108583dc7 Oops. Remove trailing whitespace in previous. 2010-09-30 19:45:24 +00:00
skrll d965c46816 Improve debug output. 2010-09-30 19:43:11 +00:00
skrll 0e07ba7138 Add the magic branch instruction that is used by GCC's
__canonicalize_funcptr_for_compare() function to fixup relocations in
order to do function pointer comparisons.

From OpenBSD.
2010-09-30 19:32:40 +00:00
skrll 06acf46b03 Introduce a new type Elf_Symindx for use in decoding the symbol hash table
section and allow this type to be overridden.

The ELF specification says it should always be uint32_t (Elf_Word), but
alpha decided to be different (not sure why). Define Elf_Symindx to be
uint64_t on alpha.

Alpha no longer uses non-standard definitions of Elf64_Sword and
Elf64_Word.  Remove the ability to override these types.

Fixes ld.elf_so after Herculean effort from me and martin.
2010-09-30 09:11:18 +00:00
matt af56990d0c Make the GOT1_MASK 64-bit clean. 2010-09-24 15:20:52 +00:00
skrll 8f77c5159b Comment reformat. 2010-09-24 12:00:10 +00:00
skrll 2c56298dd9 Wrap long line. 2010-09-24 11:59:28 +00:00
skrll 09601c884f Whitespace. 2010-09-24 11:57:11 +00:00
skrll 6229c56fea Wrap long lines
Reformat comments.
2010-09-24 11:41:46 +00:00
joerg 11fdf81f84 Avoid casting from d_val to plttype of different signedness.
Just two booleans for the same purpose.
2010-09-23 13:03:35 +00:00
wiz 8d65c98f7a Fix typo. 2010-09-21 07:05:28 +00:00
mrg df5be5736c merge bozohttpd 20100920 2010-09-20 23:11:38 +00:00
mrg 729c374954 initial import of bozohttpd 20100920. the only change missing in here is:
o  fix dynamic CGI content maps, from rudolf
2010-09-20 23:07:21 +00:00
mrg 44128f48a9 fix an error in the previous. 2010-09-20 22:18:22 +00:00
mrg 109d4102cc fix a serious error in virtual hosting support, noticed by seanb@netbsd,
and disallow ".." as a virtual host name!  also ".".

patch from sean.
2010-09-20 21:58:43 +00:00
skrll 07666b6356 Wrap long line. 2010-09-11 11:11:52 +00:00
mrg e0a4d05008 fix another compile error if NO_DAEMON_MODE is defined. also from rudolf. 2010-09-09 04:41:49 +00:00
mrg f3a95c474f fix a compile error if NO_DIRINDEX_SUPPORT is defined. from rudolf. 2010-09-08 00:47:44 +00:00
pooka 0fb1ef7452 Don't exit when running as a lib after FS is unmounted, just return
from the mainloop.
2010-08-16 22:11:55 +00:00
dogcow 172b076ece ...and free() memory malloc()ed by scandir so we don't leak. 2010-08-16 18:32:44 +00:00
dogcow 035f1ce17b readdir -> scandir and requisite changes, so that bozohttpd now sorts
directory listings.
2010-08-16 10:00:56 +00:00