Commit Graph

13 Commits

Author SHA1 Message Date
Joseph Myers 04277e02d7 Update copyright dates with scripts/update-copyrights.
* All files with FSF copyright notices: Update copyright dates
	using scripts/update-copyrights.
	* locale/programs/charmap-kw.h: Regenerated.
	* locale/programs/locfile-kw.h: Likewise.
2019-01-01 00:11:28 +00:00
Joseph Myers 688903eb3e Update copyright dates with scripts/update-copyrights.
* All files with FSF copyright notices: Update copyright dates
	using scripts/update-copyrights.
	* locale/programs/charmap-kw.h: Regenerated.
	* locale/programs/locfile-kw.h: Likewise.
2018-01-01 00:32:25 +00:00
Florian Weimer 8e1472d2c1 ld.so: Examine GLRO to detect inactive loader [BZ #20204]
GLRO (_rtld_global_ro) is read-only after initialization and can
therefore not be patched at run time, unlike the hook table addresses
and their contents, so this is a desirable hardening feature.

The hooks are only needed if ld.so has not been initialized, and this
happens only after static dlopen (dlmopen uses a single ld.so object
across all namespaces).

Reviewed-by: Carlos O'Donell <carlos@redhat.com>
2017-12-18 20:04:13 +01:00
Joseph Myers bfff8b1bec Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
Joseph Myers f7a9f785e5 Update copyright dates with scripts/update-copyrights. 2016-01-04 16:05:18 +00:00
Joseph Myers b168057aaa Update copyright dates with scripts/update-copyrights. 2015-01-02 16:29:47 +00:00
Siddhesh Poyarekar 9b42a0b3a3 Remove IS_IN_libdl
Replace with IS_IN (libdl).  No changes to generated code on x86_64.

	* dlfcn/dladdr.c: Use IS_IN.
	* dlfcn/dladdr1.c: Likewise.
	* dlfcn/dlclose.c: Likewise.
	* dlfcn/dlerror.c: Likewise.
	* dlfcn/dlinfo.c: Likewise.
	* dlfcn/dlmopen.c: Likewise.
	* dlfcn/dlopen.c: Likewise.
	* dlfcn/dlsym.c: Likewise.
	* dlfcn/dlvsym.c: Likewise.
2014-11-24 11:41:44 +05:30
Ondřej Bílka a1ffb40e32 Use glibc_likely instead __builtin_expect. 2014-02-10 15:07:12 +01:00
Allan McRae d4697bc93d Update copyright notices with scripts/update-copyrights 2014-01-01 22:00:23 +10:00
Joseph Myers 568035b787 Update copyright notices with scripts/update-copyrights. 2013-01-02 19:05:09 +00:00
Paul Eggert 59ba27a63a Replace FSF snail mail address with URLs. 2012-02-09 23:18:22 +00:00
Ulrich Drepper 5f21997b9d Update.
2004-10-18  Jakub Jelinek  <jakub@redhat.com>

	* elf/dl-libc.c (__libc_dlsym_private, __libc_register_dl_open_hook):
	New functions.
	(__libc_dlopen_mode): Call __libc_register_dl_open_hook and
	__libc_register_dlfcn_hook.
	* dlfcn/Makefile (routines, elide-routines.os): Set.
	Add rules to build and test tststatic2.
	* dlfcn/tststatic2.c: New test.
	* dlfcn/modstatic2.c: New test module.
	* dlfcn/dladdr.c: Call _dlfcn_hook from libdl.so if not NULL.
	Define __ prefixed routine in libc.a and in libdl.a just call it.
	* dlfcn/dladdr1.c: Likewise.
	* dlfcn/dlclose.c: Likewise.
	* dlfcn/dlerror.c: Likewise.
	* dlfcn/dlinfo.c: Likewise.
	* dlfcn/dlmopen.c: Likewise.
	* dlfcn/dlopen.c: Likewise.
	* dlfcn/dlopenold.c: Likewise.
	* dlfcn/dlsym.c: Likewise.
	* dlfcn/dlvsym.c: Likewise.
	* dlfcn/sdladdr.c: New file.
	* dlfcn/sdladdr1.c: New file.
	* dlfcn/sdlclose.c: New file.
	* dlfcn/sdlerror.c: New file.
	* dlfcn/sdlinfo.c: New file.
	* dlfcn/sdlopen.c: New file.
	* dlfcn/sdlsym.c: New file.
	* dlfcn/sdlvsym.c: New file.
	* dlfcn/Versions (libdl): Export _dlfcn_hook@GLIBC_PRIVATE.
	* include/dlfcn.h (DL_CALLER_DECL, DL_CALLER RETURN_ADDRESS): Define.
	(struct dlfcn_hook): New type.
	(_dlfcn_hook): New extern decl.
	(__dlopen, __dlclose, __dlsym, __dlerror, __dladdr, __dladdr1,
	__dlinfo, __dlmopen, __libc_dlsym_private,
	__libc_register_dl_open_hook, __libc_register_dlfcn_hook): New
	prototypes.
	(__dlvsym): Use DL_CALLER_DECL.
	* include/libc-symbols.h: Define libdl_hidden_proto and friends.

	* malloc/arena.c (_dl_open_hook): Extern decl.
	(ptmalloc_init): Don't call _dl_addr when dlopened from statically
	linked programs but don't use brk for them either.
2004-10-18 23:17:46 +00:00
Roland McGrath 8dd569934c 2003-03-10 Roland McGrath <roland@redhat.com>
* dlfcn/Makefile (libdl-routines): Add dladdr1.
	* dlfcn/dladdr1.c: New file.
	* dlfcn/dlfcn.h [__USE_GNU]: Declare dladdr1.
	[__USE_GNU] (RTLD_DL_SYMENT, RTLD_DL_LINKMAP): New enum constants.
	* elf/dl-addr.c (_dl_addr): Take new args, a struct link_map ** and
	a const ElfNN_Sym ** to fill in.
	* include/dlfcn.h: Update decl.  Include <link.h>.
	* dlfcn/dladdr.c (dladdr): Update caller.
	* malloc/mtrace.c (tr_where): Likewise.
	* sysdeps/generic/elf/backtracesyms.c: Likewise.
	* sysdeps/generic/elf/backtracesymsfd.c: Likewise.
	* dlfcn/Versions (libdl: GLIBC_2.3.3): New set, add dladdr1.
	* Versions.def (libdl): Define GLIBC_2.3.3 set.
2003-03-10 09:12:11 +00:00