--- a/pgp.rst Mon Nov 30 01:02:20 2015 +0200
+++ b/pgp.rst Mon Nov 30 17:09:24 2015 +0200
@@ -25,10 +25,20 @@
How export key?
===============
-::
+
+Export public key in binary (OpenGPG) form::
+
+ $ gpg --export $KEYID >$PUBKEY.asc
+ $ gpg --output $PUBKEY.asc --export $KEYID
- $ gpg -a --export $KEYID >$FILE.asc
- $ gpg --output $PRIVKEY.gpg --armor --export-secret-key $KEYID
+Export public key in text form::
+
+ $ gpg -a --export $KEYID >$PUBKEY.asc
+ $ gpg --armor --export $KEYID >$PUBKEY.asc
+
+Export private key (it still encrypted by pass-phrase)::
+
+ $ gpg --output $PRIVKEY.gpg --export-secret-key $KEYID
How create own PGP key?
=======================
@@ -44,6 +54,19 @@
$ gpg --import $keyfile
+How to get public key from private without importing to local storage?
+======================================================================
+::
+
+ tmp=$(mktemp -d)
+ gpg --homedir $tmp --import $SECKEY
+ gpg --homedir $tmp --export $ID > $PUBKEY
+ rm -rf $tmp
+
+..
+
+ http://stackoverflow.com/questions/7661500/how-to-get-public-key-from-private-in-gpg-without-using-local-storage-under
+
How submit public key to key server?
====================================
::