4.6 Where are the key files?

The key files are all the other associated files are located in ~/.gnupg. GPG automatically sets the permissions of this folder to drwx------, which means only the user owner has access to the content. All the contained files are also marked read-writeable only by the user owner.

Of the files in this folder, the most important one that you have to guard (and not to lose or expose it) is secring.gpg. This is your private key. pubring.gpg, on the other hand, is a public key that you can distribute to others.