keybase / kbpgp

OpenPGP (RFC4880) Implementation in IcedCoffeeScript
https://keybase.io/kbpgp
BSD 3-Clause "New" or "Revised" License
535 stars 74 forks source link

Deterministic KPGP Key generation #93

Open ricmoo opened 8 years ago

ricmoo commented 8 years ago

I was wondering if there was a way to deterministically generate PGP keys? Specifically with the ed25519 elliptic curve.

Basically, I would want to be able to pass in some seed and have the same key generated every time, given the same seed (for ed25519 the seed would be 256-bits, the same size as the curve).

Thanks.

maxtaco commented 8 years ago

It's doable, will take a little bit of futzing. But not ready at the moment. Plus, according to #92, we don't have Curve25519 DH support yet..

0xjjpa commented 7 years ago

Just an update here, seems you guys already implemented Curve25519 DH support in https://github.com/keybase/kbpgp/pull/121, am I correct?

0xjjpa commented 7 years ago

@ricmoo just as a thought, you could probably modify the generate function in https://github.com/keybase/kbpgp/blob/v2.0.69/src/ecc/curves.iced#L298 to receive a Uint8Array value as a parameter to use it as x to recreate a key.