diff options
author | jdp <jdp@FreeBSD.org> | 2000-08-11 03:26:30 +0000 |
---|---|---|
committer | jdp <jdp@FreeBSD.org> | 2000-08-11 03:26:30 +0000 |
commit | 42f709b55240dfcb8316476122350f6e49aeac2f (patch) | |
tree | f071ef29de7920c71a53e4da67111f1a4114676f /etc | |
parent | 0e16ee5039b7e56af67343934e645b5916f4d13e (diff) | |
download | FreeBSD-src-42f709b55240dfcb8316476122350f6e49aeac2f.zip FreeBSD-src-42f709b55240dfcb8316476122350f6e49aeac2f.tar.gz |
Add an rc.conf knob "ldconfig_insecure" to disable ldconfig's
security checks. Set the default to NO, i.e., secure.
Submitted by: Maxime Henrion <mhenrion@cybercable.fr>
Diffstat (limited to 'etc')
-rw-r--r-- | etc/defaults/rc.conf | 1 | ||||
-rw-r--r-- | etc/rc | 10 |
2 files changed, 9 insertions, 2 deletions
diff --git a/etc/defaults/rc.conf b/etc/defaults/rc.conf index c798459..001fc11 100644 --- a/etc/defaults/rc.conf +++ b/etc/defaults/rc.conf @@ -285,6 +285,7 @@ linux_enable="NO" # Linux binary compatibility loaded at startup (or NO). svr4_enable="NO" # SysVR4 emulation loaded at startup (or NO). osf1_enable="NO" # Alpha OSF/1 emulation loaded at startup (or NO). clear_tmp_enable="NO" # Clear /tmp at startup. +ldconfig_insecure="NO" # Set to YES to disable ldconfig security checks ldconfig_paths="/usr/lib/compat /usr/X11R6/lib /usr/local/lib" # shared library search paths ldconfig_paths_aout="/usr/lib/compat/aout /usr/X11R6/lib/aout /usr/local/lib/aout" @@ -379,6 +379,12 @@ esac # Make shared lib searching a little faster. Leave /usr/lib first if you # add your own entries or you may come to grief. # +ldconfig="/sbin/ldconfig" +case ${ldconfig_insecure} in +[Yy][Ee][Ss]) + ldconfig="${ldconfig} -i" + ;; +esac if [ -x /sbin/ldconfig ]; then case `/usr/bin/objformat` in elf) @@ -389,7 +395,7 @@ if [ -x /sbin/ldconfig ]; then fi done echo 'setting ELF ldconfig path:' ${_LDC} - ldconfig -elf ${_LDC} + ${ldconfig} -elf ${_LDC} ;; esac @@ -405,7 +411,7 @@ if [ -x /sbin/ldconfig ]; then fi done echo 'setting a.out ldconfig path:' ${_LDC} - ldconfig -aout ${_LDC} + ${ldconfig} -aout ${_LDC} ;; esac fi |