|
Revision tags: release/13.4.0-p5, release/13.5.0-p1, release/14.2.0-p3, release/13.5.0, release/14.2.0-p2, release/14.1.0-p8, release/13.4.0-p4, release/14.1.0-p7, release/14.2.0-p1, release/13.4.0-p3, release/14.2.0, release/13.4.0, release/14.1.0, release/13.3.0, release/14.0.0 |
|
| #
42b38843 |
| 16-Aug-2023 |
Warner Losh <[email protected]> |
Remove $FreeBSD$: one-line .h pattern
Remove /^\s*\*+\s*\$FreeBSD\$.*$\n/
|
|
Revision tags: release/13.2.0, release/12.4.0, release/13.1.0, release/12.3.0, release/13.0.0 |
|
| #
d36d6816 |
| 05-Apr-2021 |
Konstantin Belousov <[email protected]> |
rtld dl_iterate_phdr(): dlpi_tls_data is wrong
dl_iterate_phdr() dlpi_tls_data should provide the TLS module segment address, and not the TLS init segment address as it does now.
Reported by: emacs
rtld dl_iterate_phdr(): dlpi_tls_data is wrong
dl_iterate_phdr() dlpi_tls_data should provide the TLS module segment address, and not the TLS init segment address as it does now.
Reported by: [email protected] PR: 254774 Sponsored by: The FreeBSD Foundation MFC after: 1 week
show more ...
|
|
Revision tags: release/12.2.0, release/11.4.0 |
|
| #
d89d5508 |
| 26-May-2020 |
Konstantin Belousov <[email protected]> |
Add version indicators to rtld.
It is wrong to relate on __FreeBSD_version, either from include/param.h, kernel, or libc, to check for rtld features. Rtld might be from newer world than the running
Add version indicators to rtld.
It is wrong to relate on __FreeBSD_version, either from include/param.h, kernel, or libc, to check for rtld features. Rtld might be from newer world than the running userspace.
Add special private symbols exported by rtld itself, to indicate the changes in runtime behavior, and features that cannot be otherwise detected or deduced at runtime.
Note that the symbols are not exported from libc, so they intentionally cannot be linked against, and exported from the private namespace from rtld. Consumers are required to use dlsym(3). For instance, for _rtld_version_laddr_offset, user should do ptr = dlsym(RTLD_DEFAULT, "_rtld_version_laddr_offset") or even ptr = dlvsym(RTLD_DEFAULT, "_rtld_version_laddr_offset", "FBSDprivate_1.0"); Non-null ptr means that the change is present.
Also add _rtld_version__FreeBSD_version indicator to report the headers version used at time of the rtld build.
Reviewed by: jhb Sponsored by: The FreeBSD Foundation MFC after: 1 week Differential revision: https://reviews.freebsd.org/D24982
show more ...
|
|
Revision tags: release/12.1.0, release/11.3.0, release/12.0.0, release/11.2.0, release/10.4.0, release/11.1.0, release/11.0.1, release/11.0.0, release/10.3.0, release/10.2.0 |
|
| #
0e521992 |
| 03-Jan-2015 |
Konstantin Belousov <[email protected]> |
Add rtld private interface for dso to detect dynamic loading vs. static linking.
Tested by: pho, antoine (exp-run) Sponsored by: The FreeBSD Foundation MFC after: 1 week
|
|
Revision tags: release/10.1.0, release/9.3.0 |
|
| #
7a61fc5a |
| 07-May-2014 |
Mark Johnston <[email protected]> |
- Export the function added in r265456 rather than the non-existent _rtld_debug_postinit(). [1] - Use __compiler_membar() instead of inline asm in _r_debug_state() and _r_debug_postinit(). [2]
P
- Export the function added in r265456 rather than the non-existent _rtld_debug_postinit(). [1] - Use __compiler_membar() instead of inline asm in _r_debug_state() and _r_debug_postinit(). [2]
Pointy hat to: markj [1] Reported by: attilio [2] Discussed with: kib X-MFC-With: r265456
show more ...
|
| #
a8509eb2 |
| 06-May-2014 |
Mark Johnston <[email protected]> |
Add a postinit debugger hook to rtld. This will be used by dtrace(1) to halt the victim process before its entry point is called, at which point probes and DOF data are registered with the kernel. Th
Add a postinit debugger hook to rtld. This will be used by dtrace(1) to halt the victim process before its entry point is called, at which point probes and DOF data are registered with the kernel. The r_debug_state hook cannot be used for this purpose, as it is called before the program's init routines are invoked and in particular before DOF data is registered (via drti.o).
Reviewed by: kib MFC after: 2 weeks
show more ...
|
|
Revision tags: release/10.0.0, release/9.2.0, release/8.4.0, release/9.1.0, release/8.3.0_cvs, release/8.3.0 |
|
| #
5d8aec9c |
| 07-Jan-2012 |
Konstantin Belousov <[email protected]> |
Implement fdlopen(3), an rtld interface to load shared object by file descriptor.
Requested and tested by: des (previous version) Reviewed by: des, kan (previous version) MFC after: 2 weeks
|
|
Revision tags: release/9.0.0 |
|
| #
7a159e49 |
| 20-Feb-2011 |
Nathan Whitehorn <[email protected]> |
Remove a hack made obsolete by the binutils 2.17 merge.
|
|
Revision tags: release/7.4.0_cvs, release/8.2.0_cvs, release/7.4.0, release/8.2.0 |
|
| #
212f264c |
| 08-Jan-2011 |
Konstantin Belousov <[email protected]> |
In rtld, read the initial stack access mode from AT_STACKPROT as set by kernel, and parse PT_GNU_STACK phdr from linked and loaded dsos.
If the loaded dso requires executable stack, as specified by
In rtld, read the initial stack access mode from AT_STACKPROT as set by kernel, and parse PT_GNU_STACK phdr from linked and loaded dsos.
If the loaded dso requires executable stack, as specified by PF_X bit of p_flags of PT_GNU_STACK phdr, but current stack protection does not permit execution, the __pthread_map_stacks_exec symbol is looked up and called. It should be implemented in libc or threading library and change the protection mode of all thread stacks to be executable.
Provide a private interface _rtld_get_stack_prot() to export the stack access mode as calculated by rtld.
Reviewed by: kan
show more ...
|
| #
e048186a |
| 23-Aug-2010 |
Konstantin Belousov <[email protected]> |
Introduce implementation-private rtld interface _rtld_addr_phdr, which fills struct dl_phdr_info for the shared object that contains the specified address, if any.
Idea and reviewed by: kan MFC afte
Introduce implementation-private rtld interface _rtld_addr_phdr, which fills struct dl_phdr_info for the shared object that contains the specified address, if any.
Idea and reviewed by: kan MFC after: 3 weeks
show more ...
|
|
Revision tags: release/8.1.0_cvs, release/8.1.0 |
|
| #
27bd4146 |
| 10-Jul-2010 |
Nathan Whitehorn <[email protected]> |
RTLD support for powerpc64. A few small modifications to the Makefile and symbol map are required to support various consequences of the dot symbol scheme:
- Symbols beginning with a dot are reserve
RTLD support for powerpc64. A few small modifications to the Makefile and symbol map are required to support various consequences of the dot symbol scheme:
- Symbols beginning with a dot are reserved, so start private symbols with an underscore. - In order to set RTLD breakpoints, gdb must be able to locate the text entry point, not the data section function descriptor, so add .r_debug_state to the symbol map on powerpc64.
Obtained from: projects/ppc64
show more ...
|
|
Revision tags: release/7.3.0_cvs, release/7.3.0, release/8.0.0_cvs, release/8.0.0, release/7.2.0_cvs, release/7.2.0 |
|
| #
c8da4f07 |
| 03-Apr-2009 |
Konstantin Belousov <[email protected]> |
Allow the NULL, RTLD_SELF and RTLD_NEXT handles to work with dlfunc(3). dlfunc() called dlsym() to do the work, and dlsym() determines the dso that originating the call by the return address. Due to
Allow the NULL, RTLD_SELF and RTLD_NEXT handles to work with dlfunc(3). dlfunc() called dlsym() to do the work, and dlsym() determines the dso that originating the call by the return address. Due to this, dlfunc() operated as if the caller is always the libc.
To fix this, move the dlfunc() to rtld, where it can call the internal implementation of dlsym, and still correctly fetch return address. Provide usual weak stub for the symbol from libc for static binaries. dlfunc is put to FBSD_1.0 symver namespace in the ld.so export to override dlfunc@FBSD_1.0 weak symbol, exported by libc.
Reported, analyzed and tested by: Tijl Coosemans <tijl ulyssis org> PR: standards/133339 Reviewed by: kan
show more ...
|
|
Revision tags: release/7.1.0_cvs, release/7.1.0 |
|
| #
cb5c4b10 |
| 27-Nov-2008 |
Konstantin Belousov <[email protected]> |
Add two rtld exported symbols, _rtld_atfork_pre and _rtld_atfork_post. Threading library calls _pre before the fork, allowing the rtld to lock itself to ensure that other threads of the process are o
Add two rtld exported symbols, _rtld_atfork_pre and _rtld_atfork_post. Threading library calls _pre before the fork, allowing the rtld to lock itself to ensure that other threads of the process are out of dynamic linker. _post releases the locks.
This allows the rtld to have consistent state in the child. Although child may legitimately call only async-safe functions, the call may need plt relocation resolution, and this requires working rtld.
Reported and debugging help by: rink Reviewed by: kan, davidxu MFC after: 1 month (anyway, not before 7.1 is out)
show more ...
|
|
Revision tags: release/6.4.0_cvs, release/6.4.0, release/7.0.0_cvs, release/7.0.0, release/6.3.0_cvs, release/6.3.0 |
|
| #
03c4fb02 |
| 11-Jul-2007 |
Alexander Kabaev <[email protected]> |
Add r_debug_state to the list of symbols exported from rtld. GDB needs to be able to find it in order to trap shared library events from rtld.
Approved by: re (rwatson)
|
| #
7046601e |
| 01-May-2007 |
Daniel Eischen <[email protected]> |
Catch up with the private namespace change (s/FBSDprivate/FBSDprivate_1.0).
|
| #
5f864214 |
| 29-Apr-2007 |
Daniel Eischen <[email protected]> |
Use C comments since we now preprocess these files with CPP.
|
| #
3c0d0ca7 |
| 09-Apr-2007 |
Alexander Kabaev <[email protected]> |
Bring rtld exports in line with corresponding symbols exported from libc.
Disable SYMVER_DEFAULT n rtld until its implications are understood better.
|
| #
7ca8e6a6 |
| 03-Apr-2007 |
Alexander Kabaev <[email protected]> |
Prepare rtld for symbol versioning. Disable it by default for now.
|