I've been using private-public key logins on my home server for several years but I've always left PasswordAuthentication yes so that if anything untoward happened I could still login.
Of course the likelihood of anything untoward happening is hugely increased by leaving password auth enabled.

So if I set PasswordAuthentication no I obviously won't be able to login to SSH using a username/password.
But can I still login to the machine locally using a system username/password?

I'm assuming yes, since logging in locally to the physical machine would have nothing to do with SSH. But before I go ahead and disable password auth I wanted to make 100% sure.

2 Answers 2


Yes you will be able to locally login using an username/password since this is the configuration for the sshserver only and doesn't affect the local login procedure.

  • Wow 2 answers in the same minute, not sure which was first. Settled by a tie break, there are more words in this answer. Upvoted both.
    – batfastad
    Sep 13, 2012 at 12:31
  • 2
    You can login locally even if you don't have ssh daemon.
    – Khaled
    Sep 13, 2012 at 12:31

You are correct in your assumption.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.