Open lvh opened 8 years ago
Not sure that the original intent of KeyPair(byte[] secretKey)
is supposed to mimic crypto_box_seed_keypair
but rather the case where crypto_box_keypair
was used. On my branch where I was trying to get Kalium up to date with current libsodium I added a constructor that uses crypto_box_seed_keypair
explicity.
KeyPair in kalium just does the point mult with whatever the input was. The seed API in libsodium hashes the input to 32 bytes and then does the point mult. Is that intentional?
Cc @cbowdon, who might care about the behavior in caesium, since he submitted the PR for it. I might be changing this to use the libsodium API.