aboutgitcodebugslistschat
path: root/test
diff options
context:
space:
mode:
authorStefano Brivio <sbrivio@redhat.com>2024-08-26 20:41:31 +0200
committerStefano Brivio <sbrivio@redhat.com>2024-08-27 09:03:47 +0200
commit418feb37ece9ad584ec8b167861bb21a2cc3c067 (patch)
tree19d950613851ab90e7ff8838c9505f593f2cfd82 /test
parent1d6142f362c761ad800b0cbf6ab69cea426658e8 (diff)
downloadpasst-418feb37ece9ad584ec8b167861bb21a2cc3c067.tar
passt-418feb37ece9ad584ec8b167861bb21a2cc3c067.tar.gz
passt-418feb37ece9ad584ec8b167861bb21a2cc3c067.tar.bz2
passt-418feb37ece9ad584ec8b167861bb21a2cc3c067.tar.lz
passt-418feb37ece9ad584ec8b167861bb21a2cc3c067.tar.xz
passt-418feb37ece9ad584ec8b167861bb21a2cc3c067.tar.zst
passt-418feb37ece9ad584ec8b167861bb21a2cc3c067.zip
test: Look for possible sshd-session paths (if it's there at all) in mbuto's profile
Some distributions already have OpenSSH 9.8, which introduces split sshd/sshd-session binaries, and there we need to copy the binary from the host, which can be /usr/libexec/openssh/sshd-session (Fedora Rawhide), /usr/lib/ssh/sshd-session (Arch Linux), /usr/lib/openssh/sshd-session (Debian), and possibly other paths. Add at least those three, and, if we don't find sshd-session, assume we don't need it: it could very well be an older version of OpenSSH, as reported by David for Fedora 40, or perhaps another daemon (would Dropbear even work? I'm not sure). Reported-by: David Gibson <david@gibson.dropbear.id.au> Fixes: d6817b3930be ("test/passt.mbuto: Install sshd-session OpenSSH's split process") Signed-off-by: Stefano Brivio <sbrivio@redhat.com> Reviewed-by: David Gibson <david@gibson.dropbear.id.au> Tested-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'test')
-rwxr-xr-xtest/passt.mbuto11
1 files changed, 9 insertions, 2 deletions
diff --git a/test/passt.mbuto b/test/passt.mbuto
index 61865e8..138d365 100755
--- a/test/passt.mbuto
+++ b/test/passt.mbuto
@@ -13,8 +13,15 @@
PROGS="${PROGS:-ash,dash,bash ip mount ls insmod mkdir ln cat chmod lsmod
modprobe find grep mknod mv rm umount jq iperf3 dhclient hostname
sed tr chown sipcalc cut socat dd strace ping tail killall sleep sysctl
- nproc tcp_rr tcp_crr udp_rr which tee seq bc sshd ssh-keygen cmp
- /usr/lib/openssh/sshd-session}"
+ nproc tcp_rr tcp_crr udp_rr which tee seq bc sshd ssh-keygen cmp}"
+
+# OpenSSH 9.8 introduced split binaries, with sshd being the daemon, and
+# sshd-session the per-session program. We need the latter as well, and the path
+# depends on the distribution. It doesn't exist on older versions.
+for bin in /usr/lib/openssh/sshd-session /usr/lib/ssh/sshd-session \
+ /usr/libexec/openssh/sshd-session; do
+ command -v "${bin}" >/dev/null && PROGS="${PROGS} ${bin}"
+done
KMODS="${KMODS:- virtio_net virtio_pci vmw_vsock_virtio_transport}"