#!/bin/sh set -eu # The ephemeral host key is bind-mounted from the test host and can therefore # have an untrusted numeric owner. Copy it into the root-owned tmpfs before # sshd checks host-key ownership and permissions. install -o root -g root -m 0600 /fixture/host/ssh_host_ed25519_key /run/sshd/ssh_host_ed25519_key # Authorized keys are public material; root ownership prevents fixture-user mutation. install -o root -g root -m 0644 /fixture/authorized_keys /run/sshd/authorized_keys exec /usr/sbin/sshd -D -e -f /etc/ssh/sshd_config