pgp export private key with password

David Shaw dshaw at jabberwocky.com
Mon Jan 27 21:12:20 CET 2014


On Jan 27, 2014, at 3:02 PM, Uwe Brauer <oub at mat.ucm.es> wrote:

> Hello
> 
> I just tried out iPGmail a app for the iPhone which supports
> pgp. However I want to import my private key and here the trouble
> starts. For some reason iPGmail only supports private keys in armor
> format which are password protected.
> 
> But 
> gpg --export-secret-keys --passphrase hallo --armor > oub2.asc
> 
> Did not really add a passphrase, since I could import oub2.asc as a
> different user, without being asked the password.

I'm not sure I understand what you're trying to do.  --export-secret-keys doesn't add or remove a passphrase.  If the key has a passphrase, the exported one still does.  If the key has no passphrase, neither does the exported one.

If your secret key has a passphrase, then "--armor --export-secret-keys xxxxx" generates an armored key file with a passphrase.

David




More information about the Gnupg-users mailing list