Browse Source

remove support for named_chroot and named_user; always run named as user

named and chrooted to /var/named. ok deraadt@
OPENBSD_3_3
jakob 22 years ago
parent
commit
7e7e2ff075
2 changed files with 6 additions and 14 deletions
  1. +5
    -11
      src/etc/rc
  2. +1
    -3
      src/etc/rc.conf

+ 5
- 11
src/etc/rc View File

@ -1,4 +1,4 @@
# $OpenBSD: rc,v 1.219 2003/03/04 18:42:52 danh Exp $
# $OpenBSD: rc,v 1.220 2003/03/04 22:45:53 jakob Exp $
# System startup script run by init on autoboot
# or after single-user.
@ -188,9 +188,9 @@ dmesg >/var/run/dmesg.boot
echo 'starting system logger'
rm -f /dev/log
if [ "X${named_flags}" != X"NO" -a "X${named_chroot}" != "X" ]; then
rm -f ${named_chroot}/dev/log
syslogd_flags="${syslogd_flags} -a ${named_chroot}/dev/log"
if [ "X${named_flags}" != X"NO" ]; then
rm -f /var/named/dev/log
syslogd_flags="${syslogd_flags} -a /var/named/dev/log"
fi
if [ -d /var/empty ]; then
rm -f /var/empty/dev/log
@ -214,15 +214,9 @@ if ! cmp -s /etc/rndc.key /var/named/etc/rndc.key ; then
fi
fi
# $named_flags, $named_user, and $named_chroot are imported from /etc/rc.conf;
# $named_flags are imported from /etc/rc.conf;
# if $named_flags != NO, named is run.
if [ "X${named_flags}" != X"NO" ]; then
if [ "X${named_user}" != "X" -a "X${named_user}" != X"root" ]; then
named_flags="-u ${named_user} ${named_flags}"
fi
if [ "X${named_chroot}" != "X" ]; then
named_flags="-t ${named_chroot} ${named_flags}"
fi
echo 'starting named'; named $named_flags
fi


+ 1
- 3
src/etc/rc.conf View File

@ -1,6 +1,6 @@
#!/bin/sh -
#
# $OpenBSD: rc.conf,v 1.84 2002/12/27 02:26:52 lebel Exp $
# $OpenBSD: rc.conf,v 1.85 2003/03/04 22:45:53 jakob Exp $
# set these to "NO" to turn them off. otherwise, they're used as flags
routed_flags=NO # for normal use: "-q"
@ -78,8 +78,6 @@ nfsd_flags="-tun 4" # Crank the 4 for a busy NFS fileserver
amd_dir=/tmp_mnt # AMD's mount directory
amd_master=/etc/amd/master # AMD 'master' map
syslogd_flags= # add more flags, ie. "-u -a /chroot/dev/log"
named_user=named # Named should not run as root unless necessary
named_chroot=/var/named # Where to chroot named if not empty
pf_rules=/etc/pf.conf # Packet filter rules file
pflogd_flags= # add more flags, ie. "-s 256"
afs_mount_point=/afs # Mountpoint for AFS


Loading…
Cancel
Save