Open TimoGlastra opened 9 months ago
The method the bbs crate uses to generate keys from a seed is here: https://github.com/hyperledger/aries-bbssignatures-rs/blob/main/src/keys.rs#L331
This method is similar to the BLS keygen algorithm, but with Blake2 as the hash algorithm, and a different salt value. Askar currently offers the BLS keygen algorithm as an option when using Key.from_seed("bls12381g2", seed, method="bls_keygen")
(in the Python wrapper) so a compatible version could be added based on this method: https://github.com/hyperledger/aries-askar/blob/e2b6f97fd65a691dd5bfd4446478af5a81c793f2/askar-crypto/src/alg/bls.rs#L257
Is it expected that the same seed as input for Bls12381G2 key in the Mattr key generator from seed, results in the same private key being generated in Askar?
The seed
testseed000000000000000000000001
, gives me the following results (base64 encoded)