diff --git a/packages/network/openssh/init.d/51_sshd b/packages/network/openssh/init.d/51_sshd index d8effb1e9c..63c5cf5518 100644 --- a/packages/network/openssh/init.d/51_sshd +++ b/packages/network/openssh/init.d/51_sshd @@ -81,10 +81,16 @@ cp /etc/ssh/known_hosts $HOME/.ssh fi + # Check if password authentication is disabled + OPTIONS="" + + if [ "$SSHD_DISABLE_PW_AUTH" == "true" ] ; then + OPTIONS="-o 'PasswordAuthentication no'" + fi progress "Starting SSH Server" mkdir -p /var/empty chmod -R 600 /var/empty - $SSHD + eval $SSHD $OPTIONS fi )&