fabricx: use idemix with new curves to sign transactions#1236
Open
Rozerxshashank wants to merge 2 commits intohyperledger-labs:mainfrom
Open
fabricx: use idemix with new curves to sign transactions#1236Rozerxshashank wants to merge 2 commits intohyperledger-labs:mainfrom
Rozerxshashank wants to merge 2 commits intohyperledger-labs:mainfrom
Conversation
35054e1 to
93528c5
Compare
…-labs#1093) Signed-off-by: Shashank <yshashank959@gmail.com>
93528c5 to
494fe9b
Compare
Author
|
HI @adecaro, please review this when you get time. Thanks |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes : #1093
Description
This PR addresses the hardcoded
FP256BN_AMCLcurve in the Idemix implementation. The existing logic made it difficult to adopt newer, more efficient elliptic curves likeBN254(viamathlib/gnark-crypto), which offer better performance and avoid known race conditions in the older AMCL library.I've refactored the identity loading pipeline to make the elliptic curve configurable while maintaining strict backward compatibility.
Changes
curveIDfield to theMSPconfiguration struct.curveIDstring and pass the correspondingmath.CurveIDto the providers.LocalMembershipwithRegisterIdemixMSPWithCurveto allow programmatic curve selection.RegisterIdemixMSP,NewProviderWithAnyPolicy,NewDeserializer) now delegate to the new curve-aware variants using the legacyFP256BN_AMCLas the default.Testing
Verified the changes with the following steps:
platform/fabric/core/generic/msp/idemix): Passed.golangci-lint run --fix: 0 issues.Manual Configuration
You can now specify the curve in your network configuration: