After installing everything and configuring everything in the way we want, we can start on encrypting and decrypting.
When encrypting or decrypting it is possible to have more than one private key
in use. If this occurs you need to select the active key. This can be done by
using the option
-u UID or by using the option
This causes the default key to use to be replaced by wanted key.
If you want to change recipient this can be done by the option
or by the option
The command to encrypt is
gpg -e Recipient [Data]
To avoid the risk that somebody else claims to be you, it is very useful to sign everything you encrypt, see signatures.
gpg --encrypt Recipient [Data]
The command for decrypting is:
gpg [-d] [Data]
gpg [--decrypt] [Data]
stdoutis preset, but with the
-ooption you can redirect the output to a file.