The passwd command is used to manage user authentication in Linux systems. The following tasks can be accomplished using the passwd command:
Change a user’s password: The passwd command can be used to change a user’s password. A normal user may only change the password for their own account, while the superuser may change the password for any account.
Lock a user account: The -l option is used to lock the password of a specified account, and it is available to root only. The result is that the user cannot use the password to log in to the system but can use other means such as SSH public key authentication.
Therefore, the correct answers are B and E.
The manual page for passwd specifies you can change the password or use the -l option to lock the password of the named account. B and E should the correct response.
Updated response...Based on more research, The answer "E" may be "Technically" incorrect. The text for selection "E" is "Lock a user account" where the "passwd" command actually "Locks\Expires the password". Per "https://www.geeksforgeeks.org/passwd-command-in-linux-with-examples/" the "-l" option lists the following: "-l, –lock: Lock the password of user. This appends the encrypted password of the user with a character ‘!’, and thus making it unable to match with any of input password combinations. This does not disable the account but prevents the user from logging in using a password. Though other authentication methods like ssh keys can be used to login to the account." So the account is "technically "NOT" locked but the password is. The site "https://www.cyberciti.biz/faq/linux-locking-an-account/" lists "locking" the password with the "-l" is the same as locking the account. If the account were truly locked "NO" authentication would be possible.
Given that the discussions that have been put forth are, up to, a couple of years old and NO review of the questions has been done, it appears that exam topics does not research, double-check or defend their answers.
It's not their job to do so. They provide the questions with the possible answers on the test. You do the research and discuss the questions with fellow users. The minute they start giving the correct answers, I can assure you the site will go down.
Answer: B and E.
Passwd can change user password (-d) and can lock user password (-l)
https://www.geeksforgeeks.org/passwd-command-in-linux-with-examples/
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
goblue
Highly Voted 4 years agoJCoons03
Highly Voted 4 years agoAndrewGrasso
Most Recent 8 months, 4 weeks agoNetTech
1 year, 7 months agoNess12
1 year, 8 months agoMarisasa58
1 year, 9 months agohughesd010
1 year, 11 months agohughesd010
1 year, 11 months agogeocis
4 months, 3 weeks agoJarnBarn
4 months, 1 week agoJamiB1979
2 years agoMiragico
2 years, 4 months agoshosha
2 years, 6 months agoGeeGeeaR
3 years, 2 months agoAllan85
3 years, 5 months agocyberchick
3 years, 6 months agoh0st
3 years, 6 months agoMIU
3 years, 8 months agoreyman07
3 years, 9 months ago