Topic: FireGPG dont work properly when data encrypted with two private Keys

I'm using Crypt GPG PHP package to encrypt data.

so, I encrypt data using two keys:

$gpg->addEncryptKey('rafaelsereno@gmail.com');
$gpg->addEncryptKey('tmachado3@gmail.com');

//just do to a test
$gpg->addDecryptKey('tmachado3@gmail.com','1234');

And I have my data decrypted (in server side) using just one key to decrypt it.

But If I want do decrypt by clients side using FireGPG, and if I try use the private key '1234' (the one it sure works from previous test), I have the information "bad passphrase", and I can only decrypt using the first encrypt key I added (the one from rafaelsereno@gmail.com).

I think thats a bug from FireGPG because decrypt works properly on server side, using the private key that dont work with FireGPG.

EDIT: I've done several tests and the BUG is EXACTLY the following: when you have data encrypted with two keys, and you have the two keys in your key manager, FireGPG automatically choose the first private key, and then you cant decrypt with the second. I have the option "always ask for private key", but does nothing.

So in my, after the encryptation process, if I want to choose the private key I want to use, I have the delete it the other from the key manager.

Last edited by machado (2009-05-28 23:23:08)

Re: FireGPG dont work properly when data encrypted with two private Keys

Hum yes ok, but how gpg know witch key he should ask you ?

And I don't think this situation happens usually...

Re: FireGPG dont work properly when data encrypted with two private Keys

the_glu wrote:

Hum yes ok, but how gpg know witch key he should ask you ?

And I don't think this situation happens usually...

In my case, he choose the first he find. So if we want to use the second, its not possible unless you delete the first one.

Re: FireGPG dont work properly when data encrypted with two private Keys

So FireGPG use the gpg behavior, I don't understand where is the problem ..

Re: FireGPG dont work properly when data encrypted with two private Keys

the_glu wrote:

So FireGPG use the gpg behavior, I don't understand where is the problem ..

Sorry for me not explaining very good.

Ill try explain doing just one question:

If encrypt data with 2 public keys, and when im going do decrypt I have the two private keys in key manager(and I just need one to decrypt), how do I choose the second one ?

Re: FireGPG dont work properly when data encrypted with two private Keys

I don't know wink

FireGPG can't. You said (but there seem to be a misunderstanding) that gnupg can't. So there is no ways to choose the second one.

Re: FireGPG dont work properly when data encrypted with two private Keys

the_glu wrote:

I don't know wink

FireGPG can't. You said (but there seem to be a misunderstanding) that gnupg can't. So there is no ways to choose the second one.

Exactly smile

FireGPG cant, but gnupg can smile

So FireGPG should can too.