| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a new flag to /etc/ttys: onifconsole. This is equivalent to "on" if the
device is an active kernel console and "off" otherwise. This is designed to
allow serial-booting x86 systems to provide a login prompt on the serial line
by default without providing one on all systems by default. Set this flag
on x86 systems for ttyu0.
Comments and suggestions by: grehan, dteske, jilles
Approved by: re (gjb)
Relnotes: yes
Notes:
svn path=/stable/9/; revision=267243
|
| |
|
|
|
|
|
|
|
| |
Fix LD_LIBMAP.
Approved by: re (gjb)
Notes:
svn path=/stable/9/; revision=266659
|
| |
|
|
|
|
|
|
| |
Add dwarf annotations to the amd64 _rtld_bind_start to allow debuggers
to unwind around the calls from PLT to binder.
Notes:
svn path=/stable/9/; revision=264719
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Re-format the license to conform to our BSD license template as much
as possible. This does not change the wording in any way.
Remove the 3rd clause ("advertising clause") of the BSD license as
permitted by the University of Berkeley on July 22, 1999. While the
clause itself mentions Lawrence Berkeley Laboratory, UCB is the sole
copyright holder of this file.
Reviewed by: imp, emaste, eadler
Notes:
svn path=/stable/9/; revision=263832
|
| |
|
|
|
|
|
|
|
| |
MFH (r255384): add PRIVATELIB for internal-use shred libraries
MFH (r255385, r255413): add a stock libmap32.conf
MFH (r255765): always support directory mapping; rewrite libmap man page
Notes:
svn path=/stable/9/; revision=263031
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
malloc_aligned() may not leave enough space for pointer to allocated memory,
saving the pointer will overwrite bytes belongs to another memory block
unexpectly, to fix the problem, use (allocated address + sizeof(void *)) as
initial value, and slip to next aligned address, so maximum extra bytes is
sizeof(void *) + align - 1.
Tested by: Andre Albsmeier < mail at ma17 dot ata dot myota dot orgndre >
MFC r262334:
Increase alignment to size of pointer if the alignment is too small.
Some modules do not align data at least to size of pointer, they uses a
smaller alignment, but our pointer should be aligned to its native
boundary, otherwise on some platforms, hardware alignment checking
will cause bus error.
Notes:
svn path=/stable/9/; revision=262545
|
| |
|
|
|
|
|
|
|
|
|
|
| |
In sgetpwnam(), save and free pw_class like all other char members
of struct passwd. This fixes spurious "login_getclass: unknown class"
errors.
PR: 186439
Submitted by: UEMURA Tetsuya <t_uemura at macome.co.jp>
Notes:
svn path=/stable/9/; revision=262285
|
| |
|
|
|
|
|
|
|
|
| |
For variant II static TLS, properly align tls segments.
MFC r259072:
Cast Elf_Addr to void * to match the free_aligned() argument type.
Notes:
svn path=/stable/9/; revision=259293
|
| |
|
|
|
|
|
|
| |
Build an allocator for the aligned memory on top of the rtld-private
malloc.
Notes:
svn path=/stable/9/; revision=259291
|
| |
|
|
|
|
|
| |
Implement support for the interpose dso flag.
Notes:
svn path=/stable/9/; revision=256436
|
| |
|
|
|
|
|
| |
Properly terminate the result string for intermediate results.
Notes:
svn path=/stable/9/; revision=250170
|
| |
|
|
|
|
|
|
| |
Rewrite origin_subst_one() to get rid of the wrong limit on the length
of the resulting string.
Notes:
svn path=/stable/9/; revision=250040
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Map libraries linked with -Ttext-segment=base_addr at base_addr.
Normal libraries have base address 0 and are unaffected by this change.
PR: 176216
Submitted by: Damjan Jovanovic <damjan.jov@gmail.com>
Reviewed by: kib
Notes:
svn path=/stable/9/; revision=247846
|
| |
|
|
|
|
|
| |
mdoc: Only use macros inside a reference block.
Notes:
svn path=/stable/9/; revision=247650
|
| |
|
|
|
|
|
| |
Mark tftp_log() as __printflike() and deal with the fallout.
Notes:
svn path=/stable/9/; revision=247644
|
| |
|
|
|
|
|
| |
Spelling fixes for libexec/
Notes:
svn path=/stable/9/; revision=247641
|
| |
|
|
|
|
|
| |
Fix warnings found by -Wmising-variable-declarations.
Notes:
svn path=/stable/9/; revision=247638
|
| |
|
|
|
|
|
| |
Properly use LDADD & DPADD to link against libwrap.
Notes:
svn path=/stable/9/; revision=247637
|
| |
|
|
|
|
|
|
|
| |
Since clang 3.2 now has an option to suppress warnings about implicitly
promoted K&R parameters, remove the workarounds added for sendmail
components in r228558.
Notes:
svn path=/stable/9/; revision=247333
|
| |
|
|
|
|
|
|
|
|
|
| |
Use correct size in snprintf.
Remove unused buffer.
PR: 174631
Submitted by: Henning Petersen
Notes:
svn path=/stable/9/; revision=246253
|
| |
|
|
|
|
|
|
|
|
|
|
| |
atrun(8): scale default load average limit with the number of CPUs
Previously atrun refused to run jobs if load average was not below fixed limit of 1.5.
PR: 173175
Approved by: trasz (mentor)
Notes:
svn path=/stable/9/; revision=242990
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Check the return error of set[e][ug]id. While this can never fail in the
current version of FreeBSD, this isn't guarenteed by the API.
Custom security modules, or future implementations of the setuid and
setgid may fail.
Approved by: cperciva (implicit)
Notes:
svn path=/stable/9/; revision=242166
|
| |
|
|
|
|
|
|
|
|
|
| |
The reserved space for fmt was exactly sufficient for a two-digit value of
MAXLOGNAME - 1.
PR: bin/171815
Submitted by: Jeremy Huddleston Sequoia
Notes:
svn path=/stable/9/; revision=241226
|
| |
|
|
|
|
|
| |
Improve file rotation
Notes:
svn path=/stable/9/; revision=241205
|
| |
|
|
|
|
|
|
|
|
| |
Do not reference z_nodeflib for !objgiven case, thus fixing LD_PRELOAD
for a non-absolute path.
PR: bin/171604
Notes:
svn path=/stable/9/; revision=240801
|
| |
|
|
|
|
|
|
|
|
| |
Bump date missed in r202756
PR: docs/171624
Approved by: cperciva (implicit)
Notes:
svn path=/stable/9/; revision=240582
|
| |
|
|
|
|
|
|
|
|
|
| |
Implement DT_RUNPATH and -z nodefaultlib.
MFC note: The ld_library_path_rpath default value was flipped to true,
effectively reverting rtld back to the pre-patch behaviour, unless
LD_LIBRARY_PATH_RPATH environment variable is set and its value is 0/N/n.
Notes:
svn path=/stable/9/; revision=240308
|
| |
|
|
|
|
|
|
|
|
|
| |
The place where the function is called can be reached if object loading
and relocation fails too, in which case obj pointer will be NULL. Do not
call process_nodelete then, or crash will follow.
Pointy hat to: kan
Notes:
svn path=/stable/9/; revision=239471
|
| |
|
|
|
|
|
|
|
|
| |
fully loaded.
Trying to up the reference from the load loop risks missing
dependencies that have not been loaded yet.
Notes:
svn path=/stable/9/; revision=239439
|
| |
|
|
| |
Notes:
svn path=/stable/9/; revision=239435
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
A number of tftp clients, including the one in Intel's pxe boot loader,
may intentionally stop a transfer using error code 0 (i.e., EUNDEF).
These are not real errors. Avoid spamming log files with these by
logging them at level LOG_DEBUG instead.
Discussed on -hackers with an initial patch proposal; this change is an
improved approach suggested by kan@.
Notes:
svn path=/stable/9/; revision=239432
|
| |
|
|
|
|
|
|
|
|
|
| |
MFH r236892: remove mention of auth.conf from programs that don't use it
MFH r236963: remove dead code relating to auth.conf
MFH r236965 r236966 r236967 r237005 r237006 r237011: retire auth.conf
Approved by: re
Notes:
svn path=/stable/9/; revision=238481
|
| |
|
|
|
|
|
|
|
|
| |
Ensure that for the object which is a dependency for some filtee,
relocations are performed before the object's initializer is called.
Approved by: re (kensmith)
Notes:
svn path=/stable/9/; revision=238133
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Eliminate the static buffer used to read the first page of the mapped
object, and eliminate the pread(2) call as well. Mmap the first
page of the object temporaly, and unmap it on error or last use.
Potentially, this leaves one-page gap between succeeding dlopen(3),
but there are other mmap(2) consumers as well.
Fix several cases were the whole mapping of the object leaked on error.
Use MAP_PREFAULT_READ for mmap(2) calls which map real object pages
Notes:
svn path=/stable/9/; revision=237712
|
| |
|
|
|
|
|
|
|
|
| |
Add thread-local storage support for ARM to rtld-elf
Reviewed by: cognet
Obtained from: NetBSD
Notes:
svn path=/stable/9/; revision=237394
|
| |
|
|
|
|
|
|
|
| |
Remove trailing whitespace per mdoc lint warning
Approved by: cperciva (implicit)
Notes:
svn path=/stable/9/; revision=237216
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add two special directives to libmap.conf:
include <file>:
Parse the contents of file before continuing with the current file.
includedir <dir>:
Parse the contents of every file in dir that ends in .conf before continuing
with the current file.
Any file or directory encountered while processing include or includedir
directives will be parsed exactly once, even if it is encountered multiple
times.
Approved by: des (mentor)
Notes:
svn path=/stable/9/; revision=236523
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Split the symlook_obj1 into a loop iterating over the ELF object symbol
hash elements, and a helper matched_symbol() which match the given hash
entry and request, performing needed type and version checks.
MFC r234841:
Add GNU hash support for rtld.
MFC r235054:
Work around a situation where symlook_obj() could be called for the
object for which digest_dynamic1() was not done yet. Just return
EINVAL and do not try to dereference NULL buckets hash array.
Notes:
svn path=/stable/9/; revision=235396
|
| |
|
|
|
|
|
|
|
|
| |
Propagate the current state of rtld_bind_lock to dlopen_object() calls
through the filter loading call chain. This fixes attempts to
write-lock the already locked rtld_bind_lock when filter loading is
initiated by relocation of dlopening dso.
Notes:
svn path=/stable/9/; revision=234454
|
| |
|
|
|
|
|
| |
Properly handle absent AT_CANARY aux entry.
Notes:
svn path=/stable/9/; revision=234012
|
| |
|
|
|
|
|
|
| |
Remove libssp_nonshared from the rtld linking set. The only use for the
library was definition for the weak alias of __stack_chk_fail.
Notes:
svn path=/stable/9/; revision=233987
|
| |
|
|
|
|
|
| |
Provide short-circuit exit(3) implementation for rtld.
Notes:
svn path=/stable/9/; revision=233986
|
| |
|
|
|
|
|
| |
Remove superfluous extern keywords.
Notes:
svn path=/stable/9/; revision=233935
|
| |
|
|
|
|
|
| |
Centralize the calculation of the top source directory.
Notes:
svn path=/stable/9/; revision=233934
|
| |
|
|
|
|
|
|
| |
Implement xstrdup() using strlen()/xmalloc()/memcpy() already
presented in rtld, instead of pulling in libc strdup().
Notes:
svn path=/stable/9/; revision=233933
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use xmalloc() instead of malloc() in the places where malloc() calls
are assumed to not fail.
Make the xcalloc() calling conventions follow the calloc(3) calling
conventions and replace unchecked calls to calloc() with calls to
xcalloc().
Remove redundand declarations from xmalloc.c, which are already
present in rtld.h.
Notes:
svn path=/stable/9/; revision=233922
|
| |
|
|
|
|
|
| |
Remove the fragments which are not needed on FreeBSD.
Notes:
svn path=/stable/9/; revision=233921
|
| |
|
|
|
|
|
|
|
|
| |
Add a special case in do_dlsym() for TLS stored symbols.
MFC r233674:
Fix ia64 build after r233655.
Notes:
svn path=/stable/9/; revision=233833
|
| |
|
|
|
|
|
|
| |
Prevent rtld_verify_object_versions() from being called several times
for the same object.
Notes:
svn path=/stable/9/; revision=233832
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fix several problems with our ELF filters implementation.
Do not relocate twice an object which happens to be needed by loaded
binary (or dso) and some filtee opened due to symbol resolution when
relocating need objects. Record the state of the relocation
processing in Obj_Entry and short-circuit relocate_objects() if
current object already processed.
Do not call constructors for filtees loaded during the early
relocation processing before image is initialized enough to run
user-provided code. Filtees are loaded using dlopen_object(), which
normally performs relocation and initialization. If filtee is
lazy-loaded during the relocation of dso needed by the main object,
dlopen_object() runs too earlier, when most runtime services are not
yet ready.
Postpone the constructors call to the time when main binary and
depended libraries constructors are run, passing the new flag
RTLD_LO_EARLY to dlopen_object(). Symbol lookups callers inform
symlook_* functions about early stage of initialization with
SYMLOOK_EARLY. Pass flags through all functions participating in
object relocation.
Use the opportunity and fix flags argument to find_symdef() in
arch-specific reloc.c to use proper name SYMLOOK_IN_PLT instead of
true, which happen to have the same numeric value.
MFC r233777 (by kan):
Do not try to adjust stacks if dlopen_object is called too early.
MFC r233778 (by kan):
Remove extra blank line from revious commit.
MFC note: the ARM and MIPS TLS support is not merged back, so the chunks
from r233231 which fix misuse of flags in calls to find_symdef() in
the corresponding relocation type handlers were not applied. When TLS
support is merged, the rest of r233231 should be applied too.
Notes:
svn path=/stable/9/; revision=233831
|