summaryrefslogtreecommitdiff
path: root/regress
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@cvs.openbsd.org>2024-03-08 11:34:11 +0000
committerDarren Tucker <dtucker@cvs.openbsd.org>2024-03-08 11:34:11 +0000
commitb0c7683bc4710577c0b806489efb89ebcc9ee077 (patch)
tree713b267b46b4fb3bde634ce7f9d2be37cdc75738 /regress
parentc17aff94e1cada4e4b13399e7ef2a5d784d65ee7 (diff)
Invoke ProxyCommand that uses stderr redirection via $TEST_SHELL.
Fixes test when run by a user whose login shell is tcsh. Found by vinschen at redhat.com.
Diffstat (limited to 'regress')
-rw-r--r--regress/usr.bin/ssh/dynamic-forward.sh8
-rw-r--r--regress/usr.bin/ssh/test-exec.sh5
2 files changed, 8 insertions, 5 deletions
diff --git a/regress/usr.bin/ssh/dynamic-forward.sh b/regress/usr.bin/ssh/dynamic-forward.sh
index 3cda1f750f7..9f8e7667528 100644
--- a/regress/usr.bin/ssh/dynamic-forward.sh
+++ b/regress/usr.bin/ssh/dynamic-forward.sh
@@ -1,4 +1,4 @@
-# $OpenBSD: dynamic-forward.sh,v 1.16 2023/01/11 00:51:27 djm Exp $
+# $OpenBSD: dynamic-forward.sh,v 1.17 2024/03/08 11:34:10 dtucker Exp $
# Placed in the Public Domain.
tid="dynamic forwarding"
@@ -51,9 +51,9 @@ check_socks() {
for s in 4 5; do
for h in 127.0.0.1 localhost; do
trace "testing ssh socks version $s host $h (-$direction)"
- ${REAL_SSH} -q -F $OBJ/ssh_config \
- -o "ProxyCommand ${proxycmd}${s} $h $PORT 2>/dev/null" \
- somehost cat ${DATA} > ${COPY}
+ ${REAL_SSH} -q -F $OBJ/ssh_config -o \
+ "ProxyCommand ${TEST_SHELL} -c '${proxycmd}${s} $h $PORT 2>/dev/null'" \
+ somehost cat ${DATA} > ${COPY}
r=$?
if [ "x$expect_success" = "xY" ] ; then
if [ $r -ne 0 ] ; then
diff --git a/regress/usr.bin/ssh/test-exec.sh b/regress/usr.bin/ssh/test-exec.sh
index 0774373c6b4..32886bb981f 100644
--- a/regress/usr.bin/ssh/test-exec.sh
+++ b/regress/usr.bin/ssh/test-exec.sh
@@ -1,4 +1,4 @@
-# $OpenBSD: test-exec.sh,v 1.107 2024/02/19 09:25:52 dtucker Exp $
+# $OpenBSD: test-exec.sh,v 1.108 2024/03/08 11:34:10 dtucker Exp $
# Placed in the Public Domain.
#SUDO=sudo
@@ -63,6 +63,9 @@ DBCLIENT=/usr/local/bin/dbclient
DROPBEARKEY=/usr/local/bin/dropbearkey
DROPBEARCONVERT=/usr/local/bin/dropbearconvert
+# So we can override this in Portable.
+TEST_SHELL="${TEST_SHELL:-/bin/sh}"
+
# Tools used by multiple tests
NC=nc
OPENSSL_BIN="${OPENSSL_BIN:-openssl}"