You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
网页源码:
// When using the keygen party it is recommended that you pre-compute the "safe primes" and Paillier secret beforehand because this can take some time.
// This code will generate those parameters using a concurrency limit equal to the number of available CPU cores.
preParams, _ := keygen.GeneratePreParams(1 * time.Minute)
我用该库打出了android平台的aar包,但是执行生成分片的时候很慢,我不知道该怎么优化这个
网页源码:
// When using the keygen party it is recommended that you pre-compute the "safe primes" and Paillier secret beforehand because this can take some time.
// This code will generate those parameters using a concurrency limit equal to the number of available CPU cores.
preParams, _ := keygen.GeneratePreParams(1 * time.Minute)
我尝试生成2/3的mpc钱包分片,以下是我生成预参数的代码,在Android手机上生成非常慢:
// EcdsaKeygenPre 函数用于生成ECDSA密钥生成所需的预参数。
// 它会为每个参与者生成预参数,并在所有预参数生成完成后调用回调函数通知结果。
// 如果在生成过程中出现错误,会清空预参数列表并调用回调函数通知失败。
func EcdsaKeygenPre(callback KeygenGenerateCallback) {
// 循环为每个参与者生成预参数
for i := 0; i < Participants; i++ {
// 生成预参数,设置超时时间为10分钟
params, err := ecdsaKeygen.GeneratePreParams(1 * time.Minute)
// 检查生成预参数是否出错
if err != nil {
common.Logger.Errorf("Error generating pre-parameters: %v", err)
// 出错则清空预参数列表
preParams = []ecdsaKeygen.LocalPreParams{}
// 调用回调函数通知预参数生成失败
callback.OnEcdsaKeygenPreComplete(false)
return
}
}
麻烦给我一个解决方案,谢谢
The text was updated successfully, but these errors were encountered: