From 14c404e44715b3dcedab84a39a97766e6ce5125e Mon Sep 17 00:00:00 2001 From: renaud dubois Date: Tue, 10 Dec 2024 10:25:38 +0100 Subject: [PATCH] testing interpolation on ed25519 ok --- src/libMPC/SCL_ecc.mjs | 4 ++-- src/libMPC/SCL_frost.mjs | 4 ++-- src/libMPC/test_frost.mjs | 14 +++++++++----- 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/src/libMPC/SCL_ecc.mjs b/src/libMPC/SCL_ecc.mjs index 3438614..c28e325 100644 --- a/src/libMPC/SCL_ecc.mjs +++ b/src/libMPC/SCL_ecc.mjs @@ -42,8 +42,8 @@ export class SCL_ecc return publicKey; } if (this.curve === 'ed25519') { - const publicKey = this.curve.GetBase().multiply(int_from_bytes(scalar_array)); // 'true' for compressed format - return this.curve.PointCompress(publicKey);//the getPublicKey is replaced by a scalar multiplication to be compatible with key aggregation + const publicKey = this.GetBase().multiply(int_from_bytes(scalar_array)); // 'true' for compressed format + return this.PointCompress(publicKey);//the getPublicKey is replaced by a scalar multiplication to be compatible with key aggregation } throw new Error('Unsupported curve'); diff --git a/src/libMPC/SCL_frost.mjs b/src/libMPC/SCL_frost.mjs index ce34263..f9b99cc 100644 --- a/src/libMPC/SCL_frost.mjs +++ b/src/libMPC/SCL_frost.mjs @@ -145,7 +145,7 @@ export class SCL_trustedKeyGen if (this.n { - test_randomInterpolate_secret(); + test_randomInterpolate_secret('secp256k1'); + test_randomInterpolate_secret('ed25519'); + test_aggnonce(); test_noncegen();