upstream: test transfers in mux proxy mode too

OpenBSD-Regress-ID: 2edfc980628cfef3550649cab8d69fa23b5cd6c4
This commit is contained in:
djm@openbsd.org 2024-07-19 04:33:36 +00:00 committed by Damien Miller
parent 7bdfc20516
commit 63a94f99b9
No known key found for this signature in database

View File

@ -1,4 +1,4 @@
# $OpenBSD: multiplex.sh,v 1.36 2023/03/01 09:29:32 dtucker Exp $
# $OpenBSD: multiplex.sh,v 1.37 2024/07/19 04:33:36 djm Exp $
# Placed in the Public Domain.
make_tmpdir
@ -56,19 +56,20 @@ if [ $? -ne 0 ]; then
fail "environment not found"
fi
for mode in "" "-Oproxy"; do
verbose "test $tid: transfer $mode"
rm -f ${COPY}
trace "ssh transfer over $mode multiplexed connection and check result"
${SSH} $mode -F $OBJ/ssh_config -S$CTL otherhost cat ${DATA} > ${COPY}
test -f ${COPY} || fail "ssh -Sctl: failed copy ${DATA}"
cmp ${DATA} ${COPY} || fail "ssh -Sctl: corrupted copy of ${DATA}"
verbose "test $tid: transfer"
rm -f ${COPY}
trace "ssh transfer over multiplexed connection and check result"
${SSH} -F $OBJ/ssh_config -S$CTL otherhost cat ${DATA} > ${COPY}
test -f ${COPY} || fail "ssh -Sctl: failed copy ${DATA}"
cmp ${DATA} ${COPY} || fail "ssh -Sctl: corrupted copy of ${DATA}"
rm -f ${COPY}
trace "ssh transfer over multiplexed connection and check result"
${SSH} -F $OBJ/ssh_config -S $CTL otherhost cat ${DATA} > ${COPY}
test -f ${COPY} || fail "ssh -S ctl: failed copy ${DATA}"
cmp ${DATA} ${COPY} || fail "ssh -S ctl: corrupted copy of ${DATA}"
rm -f ${COPY}
trace "ssh transfer over $mode multiplexed connection and check result"
${SSH} $mode -F $OBJ/ssh_config -S $CTL otherhost cat ${DATA} > ${COPY}
test -f ${COPY} || fail "ssh -S ctl: failed copy ${DATA}"
cmp ${DATA} ${COPY} || fail "ssh -S ctl: corrupted copy of ${DATA}"
done
rm -f ${COPY}
trace "sftp transfer over multiplexed connection and check result"