Decrypting with private key and public key is missing

Guru_i gi185002 at ncr.com
Thu Oct 16 15:52:53 CEST 2008


Thank you all. Thanks "werewolf"..I got it done..and yes it was with
gpgsplit.

1) I imported "secret" key only that I am getting from my client

C:\Documents and Settings\xxxxxx\Application Data\gnupg>gpg --import
newkey.asc
gpg: keyring `C:/Documents and Settings/xxxxxx/Application
Data/gnupg\secring.gpg' created
gpg: keyring `C:/Documents and Settings/xxxxxx/Application
Data/gnupg\pubring.gpg' created
gpg: key FBCFC5F9: secret key imported
gpg: key FBCFC5F9: no valid user IDs
gpg: this may be caused by a missing self-signature
gpg: Total number processed: 1
gpg:           w/o user IDs: 1
gpg:       secret keys read: 1
gpg:   secret keys imported: 1

2) Then I use gpgsplit as you guys said

C:\Documents and Settings\xxxxxx\Application Data\gnupg>gpgsplit --no-split
--verbose --secret-to-public secring.gpg > pubring.gpg

3) Then I use list-key command..wollaaa I can see my public key getting
created now

C:\Documents and Settings\xxxxxx\Application Data\gnupg>gpg --list-key
gpg: C:/Documents and Settings/xxxxxx/Application Data/gnupg\trustdb.gpg:
trustdb created
C:/Documents and Settings/xxxxxx/Application Data/gnupg\pubring.gpg
---------------------------------------------------------------------
pub   1024R/FBCFC5F9 2008-10-06
uid                  vijay
sub   1024R/BE7137CF 2008-10-06


4) Finally to decryption 

C:\Documents and Settings\gi185002\Application Data\gnupg>gpg -o file.txt
--decrypt "C:\Documents and Settings\gi185002\Desktop\file.pgp"
gpg: encrypted with 1024-bit RSA key, ID FBCFC5F9, created 2008-10-06
      "vijay"

One more thing on my first question..I saw this just now and now I know why
my decryption failed with only secret key
http://www.gnupg.org/faq.html (See 4.6)

I love this group!!
==============================================================================

Guru_i wrote:
> 
> Thank you all your response. I will try with "gpgsplit". But I do have
> secret key in my seckeyring
> 
> C:/Documents and Settings/xxxxx/Application Data/gnupg\secring.gpg
> ---------------------------------------------------------------------
> sec   1024R/FBCFC5F9 2008-10-06
> uid                  vijay
> 
> But I am not sure why GPG can not see it during decryption. Besides the
> key that I got was generated using PGP CL.
> 
> Thanks
> guru
> 
> 
> David Shaw wrote:
>> 
>> On Oct 15, 2008, at 4:54 PM, Guru_i wrote:
>> 
>>>
>>> Hi Im using GPG CL 1.4.9.
>>> case is -
>>> 1)somebody (trusted) is generating key pair on my behalf(as proxy).  
>>> But he
>>> is sending me only my secret key and NOT public key.
>>> 2) I was able to import the secret key in gpg keyring using
>>> --allow-secret-key-import command
>>> 3) But when I try to decrypt the file (which was encrypted using my  
>>> public
>>> key its not with me though) I get error message such as
>>>
>>> gpg: decryption failed: secret key not available. Though I know I have
>>> secret key with me.
>> 
>> There is a lot that doesn't follow here.  The --allow-secret-key- 
>> import command is a no-op in version 1.4.9, so if you had to use it to  
>> import your key, then you're not using 1.4.9.
>> 
>> Also, if you were using 1.4.9, when you imported your secret key, it  
>> would automatically create a public key for you.  This is built in,  
>> and is on by default.
>> 
>> Finally, that error message means that your secret key was not, in  
>> fact, imported.  It says nothing about your public key.
>> 
>> Given all of that, I suspect you didn't import your secret key after  
>> all.
>> 
>> To import a secret key, do:
>>     gpg --import (the secret key file)
>> 
>> David
>> 
>> _______________________________________________
>> Gnupg-users mailing list
>> Gnupg-users at gnupg.org
>> http://lists.gnupg.org/mailman/listinfo/gnupg-users
>> 
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Decrypting-with-private-key-and-public-key-is-missing-tp19995558p20014132.html
Sent from the GnuPG - User mailing list archive at Nabble.com.




More information about the Gnupg-users mailing list