14.3 Managing GnuPG
Key management:
$ gpg --edit-key user_ID # "help" for help, interactive
$ gpg -o file --exports # export all keys to file
$ gpg --imports file # import all keys from file
$ gpg --send-keys user_ID # send key of user_ID to keyserver
$ gpg --recv-keys user_ID # recv. key of user_ID from keyserver
$ gpg --list-keys user_ID # list keys of user_ID
$ gpg --list-sigs user_ID # list sig. of user_ID
$ gpg --check-sigs user_ID # check sig. of user_ID
$ gpg --fingerprint user_ID # check fingerprint of user_ID
$ gpg --list-sigs | grep '^sig' | grep '[User id not found]' \
| awk '{print $2}' | sort -u | xargs gpg --recv-keys # get unknown keys
# update keys for all unknown sigs.
$ gpg --refresh-keys # update local keyring
Trust code:
- No ownertrust assigned / not yet calculated.
e Trust calculation has failed.
q Not enough information for calculation.
n Never trust this key.
m Marginally trusted.
f Fully trusted.
u Ultimately trusted.
The following will upload my key "A8061F32" to the popular
keyserver hkp://subkeys.pgp.net:
$ gpg --keyserver hkp://subkeys.pgp.net --send-keys A8061F32