summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2020-05-05 17:55:10 +0100
committerRoy Marples <roy@marples.name>2020-05-05 17:55:10 +0100
commitc0567cc03ec3a75d8edab2abb5789efda54d4c66 (patch)
treec49887a28a5ebee009a64e878999a9718cb6ece4 /configure
parent4934b0f3357194d28c57f6561d74442f4c7430e5 (diff)
downloaddhcpcd-c0567cc03ec3a75d8edab2abb5789efda54d4c66.tar.xz
privsep: Allow a blank string to force privsep users home directory
So FreeBSD users can set it like other OS's if they so choose.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure6
1 files changed, 5 insertions, 1 deletions
diff --git a/configure b/configure
index 58fcd808..ebf104c4 100755
--- a/configure
+++ b/configure
@@ -583,7 +583,11 @@ if [ "$PRIVSEP" = yes ]; then
echo "PRIVSEP_USER?= $PRIVSEP_USER" >>$CONFIG_MK
if [ -n "$PRIVSEP_CHROOT" ]; then
echo "PRIVSEP_CHROOT= $PRIVSEP_CHROOT" >>$CONFIG_MK
- echo "SED_CHROOT= -e 's:@CHDIR^@.*@CHDIR\$\$@:default of:g' -e 's:@CHDIR@:.Pa \${PRIVSEP_CHROOT} .:g'" >>$CONFIG_MK
+ cat <<EOF >>$CONFIG_MK
+SED_CHROOT= -e 's:@CHDIR^@.*@CHDIR\$\$@:default of:g' \\
+ -e 's:@CHDIR1@:.Pa \${PRIVSEP_CHROOT} .:g' \\
+ -e 's:@CHDIR2@:A blank string chroots to the privileged separation users home directory.:g'
+EOF
fi
echo "#ifndef PRIVSEP_USER" >>$CONFIG_H
echo "#define PRIVSEP_USER \"$PRIVSEP_USER\"" >>$CONFIG_H