1
0
mirror of https://github.com/tiyn/wiki.git synced 2026-03-18 20:14:47 +01:00

added openpgp and linked it

This commit is contained in:
2025-11-22 08:45:19 +01:00
parent 52aa5b2433
commit f5bae3580d
3 changed files with 61 additions and 2 deletions

View File

@@ -1,7 +1,7 @@
# GPG
[GNU Privacy Guard](https://gnupg.org/) - short GnuPG or just GPG - is a free and open-source
implementation of OpenPGP from [RFC 4880](https://datatracker.ietf.org/doc/html/rfc4880).
implementation of [OpenPGP](/wiki/openpgp.md).
It is used to savely encrypt and decrypt messages or files using assymetric encryption.
## Setup
@@ -13,6 +13,15 @@ Sometimes it is also called `gnupg2`.
This section addresses the usage of the Open GPG.
### List or Find a Key
To find a key use the following command.
`<query>` is a search string and is optional.
```sh
gpg --list-keys <query>
```
### Generating a Key Pair
A fast way to generate a key pair is by running the following command.
@@ -104,6 +113,27 @@ gpg --recv-key <id>
gpg --lsign <id>
```
### Managing Multiple Users and E-Mails of an Existing Secret Key
A secret key can have more than one e-mail assigned to it.
After generating the key however only a single user is added by default.
To add another one use the following command where `<key-id>` is the id of the key to add the
e-mail to.
```sh
gpg --edit-key <key-id>
```
Afterwards a console will open.
Using `adduid` another user can be added by following the on-screen instructions.
Afterwards `save` will save the progress and exit from the console.
To delete an existing user and e-mail also open the edit-console.
Then list the existing users using the command `uid` and select the user id of the key to delete
with `uid <id>` where `<id>` is the key to delete.
Then delete it with `deluid` and save with `save`.
## Troubleshooting
This section will focus on errors and the fixing of errors of GPG.