#!/bin/sh failsafe_sshd () { # if dropbear is executable it can handle failsafe [ -x /usr/sbin/dropbear ] && return sshd_tmpdir=/tmp/sshd mkdir $sshd_tmpdir for type in ed25519; do key=$sshd_tmpdir/ssh_host_${type}_key ssh-keygen -N '' -t ${type} -f ${key} done mkdir -m 0700 -p /var/empty cat > $sshd_tmpdir/sshd_config <