LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   importing private gpg key into ubuntu... (https://www.linuxquestions.org/questions/linux-newbie-8/importing-private-gpg-key-into-ubuntu-639185/)

mia_tech 05-01-2008 02:50 PM

importing private gpg key into ubuntu...
 
I've genareted a gpg key pair using gnu privacy assistant, on a windows machine, and now I need to import the private key on my ubuntu box, but after exporting it and backing it up from windows to a share drive, I'm trying to import it into my ubuntu box and I point to the .txt file on the share drive, but the problem is that it says that it didn't find any keys?
what's the proper way to go about this?

thanks

farslayer 05-01-2008 03:59 PM

a key would typically be .asc not .txt

On the Windows Machine
Code:

gpg --list-secret-keys

gpg --export-secret-keys -o filename.asc username@somedomain.com

copy filename.asc to your linux box, then do the following
Code:


gpg --import filename.asc

gpg --list-secret-keys

you should NOT leave that .asc file with your secret key laying around, since anyone would be able to import it.. thats a security risk.
you SHOULD create a revocation certificate and store it in a safe place in case your key is compromised or you loose it,



useful reference to gpg:

http://cryptnet.net/fdp/crypto/keysi...ing_party.html
http://www.gnupg.org/gph/en/manual.html
http://dewinter.com/gnupg_howto/engl...MiniHowto.html

mia_tech 05-02-2008 04:55 AM

thanks for the help!

mia_tech 05-02-2008 02:26 PM

by the way what is the propose of the email address when exporting private key in the example you provided?

thanks

mia_tech 05-02-2008 02:30 PM

well, after importing the key to my ubuntu box, the import went just fine, the only problem is when I receive encrypted mail, it prompt me for the password to decrypt it, but after I enter it, it say that it could not decrypt the message....I'm using firegpg firefox extension to encrypt and decrypt my google mail, but if I decrypt the message in the computer where the key was originated it works...any help appreciated

Thanks

farslayer 05-02-2008 08:36 PM

well the email address is the address I used when I generated the key and sent it up to the key server

I use the enigmail plugin with Thunderbird and GPG to sign and encrypt my messages. if you get an email from my address signed / encrypted with that key you can retrieve the public key from the key server..

the keysigning party how-to Link I posted should explain how it all works far better than I could.

What does it show as the trust level for the key on the new box ? (Ultimate or none ?)

When you list the key on the new machine does it look correct ? does the fingerprint of the key match the finger print of hte key on the other OS ?

mia_tech 05-03-2008 03:07 AM

I was able to import the key, on my ubuntu box, but I was using firegpg on firefox to encrypt and decrypt messages, but some how it wasn't decrypting the messages, after that I installed enigmail and it worked just fine...something about your post, you said that if you send me an encrypted mail I should be able to retrieve the key from the server... I thought that if I wanted you to send me an encrypted mail, I would have to send you my public key for you to encrypt the email, and the private key is resident on your computer, and password protected...is that how it works?

thanks


All times are GMT -5. The time now is 02:08 AM.