summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordtucker@openbsd.org <dtucker@openbsd.org>2023-03-02 11:10:27 +0000
committerDarren Tucker <dtucker@dtucker.net>2023-03-02 22:33:12 +1100
commit5fc60e8246c36b8255f72a937ebe9787b39648c6 (patch)
tree6cbfbe896ba246259ae496e026b525fbc0615e31
parent0d514659b23a257247491179cfbb53a6dd64e164 (diff)
upstream: Remove SUDO in proxy command wrapper. Anything that needs
sudo is already run by it, and it breaks if root isn't in sudoers. OpenBSD-Regress-ID: 6cf22fda32a89c16915f31a6ed9bbdbef2a3bac9
-rw-r--r--regress/test-exec.sh10
1 files changed, 5 insertions, 5 deletions
diff --git a/regress/test-exec.sh b/regress/test-exec.sh
index 0ba30d58..eaa12992 100644
--- a/regress/test-exec.sh
+++ b/regress/test-exec.sh
@@ -1,4 +1,4 @@
-# $OpenBSD: test-exec.sh,v 1.97 2023/03/02 08:24:41 dtucker Exp $
+# $OpenBSD: test-exec.sh,v 1.98 2023/03/02 11:10:27 dtucker Exp $
# Placed in the Public Domain.
#SUDO=sudo
@@ -301,8 +301,8 @@ logfile="${TEST_SSH_LOGDIR}/\${timestamp}.ssh.\$\$.log"
echo "Executing: ${SSH} \$@" log \${logfile} >>$TEST_REGRESS_LOGFILE
echo "Executing: ${SSH} \$@" >>\${logfile}
for i in "\$@";do shift;case "\$i" in -q):;; *) set -- "\$@" "\$i";;esac;done
-$SUDO rm -f $TEST_SSH_LOGFILE
-ln -s \${logfile} $TEST_SSH_LOGFILE
+rm -f $TEST_SSH_LOGFILE
+ln -f -s \${logfile} $TEST_SSH_LOGFILE
exec ${SSH} -E\${logfile} "\$@"
EOD
@@ -316,8 +316,8 @@ cat >$SSHDLOGWRAP <<EOD
#!/bin/sh
timestamp="\`$OBJ/timestamp\`"
logfile="${TEST_SSH_LOGDIR}/\${timestamp}.sshd.\$\$.log"
-$SUDO rm -f $TEST_SSHD_LOGFILE
-ln -s \${logfile} $TEST_SSHD_LOGFILE
+rm -f $TEST_SSHD_LOGFILE
+ln -f -s \${logfile} $TEST_SSHD_LOGFILE
echo "Executing: ${SSHD} \$@" log \${logfile} >>$TEST_REGRESS_LOGFILE
echo "Executing: ${SSHD} \$@" >>\${logfile}
exec ${SSHD} -E\${logfile} "\$@"