ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 159 - XK0-005 discussion

Report
Export

During a security scan, the password of an SSH key file appeared to be too weak and was cracked.

Which of the following commands would allow a user to choose a stronger password and set it on the existing SSH key file?

A.
passwd
Answers
A.
passwd
B.
ssh
Answers
B.
ssh
C.
ssh-keygen
Answers
C.
ssh-keygen
D.
pwgen
Answers
D.
pwgen
Suggested answer: C

Explanation:

The command that would allow a user to choose a stronger password and set it on the existing SSH key file is ssh-keygen -p -f <keyfile>. This command uses the ssh-keygen tool, which is used to generate, manage, and convert authentication keys for SSH. The -p option stands for passphrase, and it allows the user to change or remove the passphrase of an existing private key file. The -f option specifies the filename of the key file. The command will prompt the user for the old passphrase, and then for the new passphrase twice.

The other options are not correct commands for changing the password of an SSH key file. The passwd command is used to change the password of a user account on a Linux system, not an SSH key file. The ssh command is used to log in to a remote system using SSH, not to change the password of an SSH key file. The pwgen command is used to generate random passwords, not to change the password of an SSH key file.

Reference: ssh-keygen(1) - Linux manual page; How To: Change Passphrase for SSH Private Key - Unix Tutorial

asked 02/10/2024
Franklin Leon
36 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first