Index ¦ Archives


GnuPG is a complete and free implementation of the OpenPGP standard as defined by RFC4880 (also known as PGP). GnuPG allows to encrypt and sign your data and communication, features a versatile key management system as well as access modules for all kinds of public key directories. GnuPG, also known as GPG, is a command line tool with features for easy integration with other applications. GnuPG is Free Software (meaning that it respects your freedom). It can be freely used, modified and distributed under the terms of the GNU General Public License.

Generating keys

gpg2 --gen-key

Listing keys

gpg2 --list-keys

Exporting a public key

gpg2 --armor --export > publickey

Importing a public key

gpg2 --import friend.gpg
gpg2 --edit-key

Encrypting and decrypting documents

gpg2 --output doc.gpg --encrypt --recipient doc
gpg2 --output doc --descript doc.gpg
gpg2 --output doc.gpg --symmetric doc


If you have problems with pinentry program, try (overwrite your correct path to pinentry program):

gpg-agent --daemon --use-standard-socket --pinentry-program /home/dani/.guix-profile/bin/pinentry-curses


© 2000-2018 by Daniel Pimentel (d4n1). Under MIT.