-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: configurable ecdsa curve and support secp256k1 #45
base: main
Are you sure you want to change the base?
Conversation
2bf1e67
to
581781f
Compare
@@ -108,9 +109,9 @@ func (parties parties) Mapping() map[string]*tss.PartyID { | |||
} | |||
|
|||
func TestTSS(t *testing.T) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should add another test which initializes it with secp256k1.
Perhaps add a loop that iterates over both curve options?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have added a loop to iterate over the curves
test/binance/ecdsa_test.go
Outdated
@@ -31,18 +36,20 @@ func TestFastThresholdBinanceECDSA(t *testing.T) { | |||
var signatureAlgorithms func([]*commLogger) (func(uint16) KeyGenerator, func(uint16) Signer) | |||
|
|||
verifySig = verifySignatureECDSA | |||
signatureAlgorithms = ecdsaKeygenAndSign | |||
signatureAlgorithms = func(loggers []*commLogger) (func(uint16) KeyGenerator, func(uint16) Signer) { | |||
return ecdsaKeygenAndSign(elliptic.P256(), loggers) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same thing, let's have a test case which initializes an instance with secp256k1.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have added a loop to iterate over the curves
Signed-off-by: lanford33 <[email protected]>
Signed-off-by: lanford33 <[email protected]>
29e6d04
to
2657fed
Compare
@@ -49,6 +49,8 @@ require ( | |||
gopkg.in/yaml.v3 v3.0.1 // indirect | |||
) | |||
|
|||
replace github.com/IBM/TSS/mpc/binance/ecdsa => ../mpc/binance/ecdsa |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no, let's not do this.
You can make a change to the mpc/binance/ecdsa
package in this PR, and then wait for this PR to be merged, and then make a new PR that would just take the latest version into the go.mod
of the test
module.
This pull request introduces support for different elliptic curves in the
mpc/binance/ecdsa
package. The changes primarily involve modifying theparty
struct and related methods to accept and utilize an elliptic curve parameter. Additionally, the test files are updated to accommodate these changes.