I read this article which explained very well how to setup pgp on osx, but I'm planning to use the generated keys for signing git commits, so I figure I need to transfer the keys to my other computer. Is this correct? and if so how do I go about transferring the keys?
Yes, you will need to transfer the keys. Mac and Linux work the same, storing the keys in ~/.gnupg
. The safest way to transfer the files is using scp
(part of ssh):
scp -rp ~/.gnupg othermachine:
However, you will need to have ssh
working first.
Transferring them with, say, a USB flash drive isn't such a great idea because your private key will be left behind on that drive even after you've deleted the file.
I don't know about the location of the directory on Windows. The gpg documentation will say, and the contents will almost certainly be the same.
It depends on PGP software. All you need to do - is to found, where your keyrings files are physically located, and copy those files to the new computer. Or, export your keys from PGP software, and import them on the other side.