nerdexam
CompTIA

XK0-005 · Question #1887

A user test has set up SSH keys for passwordless authentication, but the server is still prompting for a password. Given the following output: Which of the following is the cause of this issue?

The correct answer is D. The user forgot to add the public key to the authorited_keys file. The empty authorized_keys (0 bytes) means SSH has no public key to match, so it falls back to password authentication. Copying id_rsa.pub into ~/.ssh/authorized_keys will resolve the issue.

Troubleshooting

Question

A user test has set up SSH keys for passwordless authentication, but the server is still prompting for a password. Given the following output: Which of the following is the cause of this issue?

Exhibit

XK0-005 question #1887 exhibit

Options

  • AThe RSA key does not meet the complexity requirements.
  • BThe passphrase needs to be provided when creating the key.
  • CThe wrong permissions are set on id_rsa file.
  • DThe user forgot to add the public key to the authorited_keys file.

How the community answered

(53 responses)
  • A
    9% (5)
  • B
    4% (2)
  • C
    6% (3)
  • D
    81% (43)

Explanation

The empty authorized_keys (0 bytes) means SSH has no public key to match, so it falls back to password authentication. Copying id_rsa.pub into ~/.ssh/authorized_keys will resolve the issue.

Topics

#SSH#Public Key Authentication#authorized_keys#Authentication Failure

Community Discussion

No community discussion yet for this question.

Full XK0-005 Practice