Bitzu

CPSA ยท Unix network file, trust and remote access services

SSH versions and authentication mechanisms

SSH-1 vs SSH-2, password, key and host-based authentication, identifying server software.

Key points

  • SSH has two protocol generations.
  • SSH-1: obsolete and cryptographically weak; modern OpenSSH speaks only SSH-2.
  • Banner: SSH-2.0-OpenSSH_<version> identifies the protocol and often the software.
  • Authentication: password, public key (the private key stays on the client), host-based (trusts a client host, off by default in OpenSSH).
  • Public key authentication is generally preferred over passwords.

Source: https://man.openbsd.org/sshd_config

Practice questions

Single choice

Which sshd authentication method relies on the client host being trusted, similar in spirit to rhosts-style trust?

  1. Host-based authentication
  2. Public key authentication
  3. Password authentication
  4. Keyboard challenge only
Show answer

Answer: A. Host-based authentication

Host-based authentication trusts the client host (combined with host key verification) and is off by default. Public key and password authentication verify the user instead.

Select all that apply

Which are authentication mechanisms supported by OpenSSH's sshd?

  1. Password
  2. Public key
  3. Host-based
  4. Anonymous guest login
  5. NetBIOS name authentication
Show answer

Answer: A. Password, B. Public key, C. Host-based

Password, public key and host-based authentication are all configurable in sshd_config. Anonymous access and NetBIOS authentication are not SSH methods.

True or false

True or false: in public key authentication, the user's private key is sent to the server during login.

Show answer

Answer: False

False. Only a proof made with the private key is used; the private key never leaves the client. The server holds the public key in authorized_keys.

Practice 8 questions on this topic in Bitzu

Short lessons, instant explanations and spaced review of what you get wrong. Free on iOS and Android.

Download on the App StoreGet it on Google Play

More CPSA topics in this module