Use a non-constant generator in FROST

This commit is contained in:
Luke Parker
2022-08-13 05:07:07 -04:00
parent 6f776ff004
commit 885d816309
12 changed files with 29 additions and 24 deletions

View File

@@ -99,7 +99,7 @@ pub fn recover<C: Curve>(keys: &HashMap<u16, FrostKeys<C>>) -> C::F {
let group_private = keys.iter().fold(C::F::zero(), |accum, (i, keys)| {
accum + (keys.secret_share() * lagrange::<C::F>(*i, &included))
});
assert_eq!(C::GENERATOR * group_private, first.group_key(), "failed to recover keys");
assert_eq!(C::generator() * group_private, first.group_key(), "failed to recover keys");
group_private
}