LFCS · Question #403
Which command is used to add an additional name, email address and comment to an existing private key?
The correct answer is A. gpg editkey name followed with the adduid command. To add an additional name, email address, and comment (User ID) to an existing private key, you must use gpg editkey followed by the adduid subcommand.
Question
Options
- Agpg editkey name followed with the adduid command.
- Bgpg addsubkey name
- Cgpg addalias name
- Dgpg genalias name
How the community answered
(23 responses)- A96% (22)
- D4% (1)
Why each option
To add an additional name, email address, and comment (User ID) to an existing private key, you must use `gpg editkey` followed by the `adduid` subcommand.
The `gpg --edit-key <name>` command opens an interactive key management interface, where the `adduid` subcommand can then be used to add an additional User ID, which includes a name, email, and comment, to the selected private key.
`gpg addsubkey` is used to add a new subkey for encryption or signing to an existing primary key, not to add a User ID.
`gpg addalias` is not a standard GPG command for adding User IDs.
`gpg genalias` is not a standard GPG command for generating User IDs.
Concept tested: GPG key User ID management
Source: https://gnupg.org/documentation/manuals/gnupg/Manage-Your-Keys.html#Add-User-ID
Topics
Community Discussion
No community discussion yet for this question.