Skip to content

Comments

feat: configurable ecdsa curve and support secp256k1#45

Open
LanfordCai wants to merge 2 commits intoIBM:mainfrom
LanfordCai:feature/configurable_ecdsa_curve
Open

feat: configurable ecdsa curve and support secp256k1#45
LanfordCai wants to merge 2 commits intoIBM:mainfrom
LanfordCai:feature/configurable_ecdsa_curve

Conversation

@LanfordCai
Copy link

This pull request introduces support for different elliptic curves in the mpc/binance/ecdsa package. The changes primarily involve modifying the party struct and related methods to accept and utilize an elliptic curve parameter. Additionally, the test files are updated to accommodate these changes.

@LanfordCai LanfordCai force-pushed the feature/configurable_ecdsa_curve branch from 2bf1e67 to 581781f Compare December 28, 2024 03:23
@@ -108,9 +109,9 @@ func (parties parties) Mapping() map[string]*tss.PartyID {
}

func TestTSS(t *testing.T) {
Copy link
Contributor

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?

Copy link
Author

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

verifySig = verifySignatureECDSA
signatureAlgorithms = ecdsaKeygenAndSign
signatureAlgorithms = func(loggers []*commLogger) (func(uint16) KeyGenerator, func(uint16) Signer) {
return ecdsaKeygenAndSign(elliptic.P256(), loggers)
Copy link
Contributor

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.

Copy link
Author

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 <lanfordcai@outlook.com>
Signed-off-by: lanford33 <lanfordcai@outlook.com>
@LanfordCai LanfordCai force-pushed the feature/configurable_ecdsa_curve branch from 29e6d04 to 2657fed Compare December 29, 2024 10:49
gopkg.in/yaml.v3 v3.0.1 // indirect
)

replace github.com/IBM/TSS/mpc/binance/ecdsa => ../mpc/binance/ecdsa
Copy link
Contributor

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants