Export private key

Dino Edwards dino.edwards at mydirectmail.net
Wed Jan 6 15:14:32 CET 2021


Hello all,


In the past I used to be able to export a private key using the following command:

/usr/bin/gpg --homedir /opt/.gnupg/ --export-secret-key -a "SOMEKEYID" > /opt /tmp/private.key

Something changed in the code and it now prompts me for the key password before it proceeds. I see the value in this, however this is problematic when I'm trying to automate the export to use in an application.

What is the correct way to pass the key password in the command line in order to export the private key without getting the password prompt?

Thanks in advance


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnupg-users/attachments/20210106/ca5fc972/attachment.html>


More information about the Gnupg-users mailing list