enable both password and key file to ssh logon in ?

February 17, 2015 4.7k views

one vps server and two client machine.
Can i set the vps server to be logon in via password on machine 1 at the same time to be logon in via key file on machine 2?

2 Answers

Yes, that's the default setting actually. Just set up an SSH key for your user and when you connect to your droplet without an ssh key (machine 2) it will fall back to a password prompt.

by Etel Sverdlov
SSH keys provide a more secure way of logging into a virtual private server with SSH than using a password alone. With SSH keys, users can log into a server without a password. This tutorial explains how to generate, use, and upload an SSH Key Pair.

This doesn't seem to be true anymore (no fallback to password). I also can't find a setting. Am I missing something?

Have another answer? Share your knowledge.