First, open the GPG Keychain and choose New.
Next, fill out the Wizard making certain selections.
- ✓ Upload the public key
- Key type should be RSA and RSA (default)
- Length should be 4096.
- Expiration should be any value, but the default value is 4 years from now.
Right-click on your name, and choose Export…
Export your key, and save it somewhere where you can share it (e.g., Desktop, Dropbox, iCloud Drive).
-
Include your secret key ONLY IF you want to backup your secret key. Never share this with anybody!
-
If you plan to share your key with someone else, or otherwise make it public, UNCHECK the checkbox.
There are different ways to import the key. The first is to double-click the .asc
file.
The second is to view the file with QuickLook, then choose to Open with GPG Keychain…
The third is to open the GPG Keychain, then drag one or more files into its window.
You can right-click on a file, choose Services, then choose OpenPGP: Encrypt file…
You will see a prompt which allows you to select which user to encrypt the file for.
NOTE: You will need that person's GPG Public Key to be imported first.
If you are the authorized recipient of an encrypted file, you can do the following.
NOTE: You will not be able to open an encrypted file that was not meant for you.
You can right-click on a file, choose Services, then choose OpenPGP: Decrypt file…