Unverified Commit 3cfe2129 authored by Oleh Nikolaiev's avatar Oleh Nikolaiev Committed by GitHub

Merge branch 'develop' into feature/SKALE-4128-modify-release-process

parents f8824c98 25ea58db
Subproject commit 82884ec89e84539f25af206a0148ca34c35e078f
Subproject commit 75972a810b8b1422004443028beedfef2288be50
......@@ -174,6 +174,11 @@ vector <libff::alt_bn128_Fr> SplitStringToFr(const char *coeffs, const char symb
return result;
}
bool isG2( const libff::alt_bn128_G2& point ) {
return point.is_well_formed() &&
libff::alt_bn128_G2::order() * point == libff::alt_bn128_G2::zero();
}
int gen_dkg_poly(char *secret, unsigned _t) {
int status = 1;
......@@ -456,6 +461,10 @@ int Verification(char *public_shares, mpz_t decr_secret_share, int _t, int ind)
pub_share.Y.c1 = libff::alt_bn128_Fq(y_c1_str.c_str());
pub_share.Z = libff::alt_bn128_Fq2::one();
if ( !isG2( pub_share ) ) {
ret = 3;
return ret;
}
pub_shares.push_back(pub_share);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment