Yes, this could be an issue.

If you knew what id you wanted to use you could call
the getPublicKeysForKeyId()/getPrivateKeyForKeyId() functions.  Looking up
by address is pretty common in most openpgp.js implementations, because we
don't know the key ID we're looking for but do know the email address.

Sean


On Sun, May 12, 2013 at 12:13 PM, emma sculateur <[email protected]>wrote:

> Hi all,
>
> First of all, thanks for openpgpjs :)
>
> I have a question :
>
> If [email protected] generates a 2 or more key pairs. I can get the keys
> with :
>     var privateKeys = getPrivateKeyForAddress([email protected]);
>     var publicKeys = getPublicKeyForAddress([email protected]);
>
> But am I sure sur privateKeys[i] is associated with publicKeys[i] ?
> How do you handle the cases where there are several pair associated to the
> same email address ?
>
> Thank you in advance.
>
> _______________________________________________
>
> http://openpgpjs.org
>
>
_______________________________________________

http://openpgpjs.org

Reply via email to