-
Notifications
You must be signed in to change notification settings - Fork 549
Secp256r1 precompile: switch to BoringSSL #8437
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
Conversation
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.
Pull Request Overview
This pull request implements the switch to the secp256r1 package using BoringSSL for signature verification and updates associated benchmarks and tests.
- Replaces manual ECDsa-based signature verification with a call to Secp256r1.VerifySignature.
- Updates benchmark input file handling and adjusts the benchmark attributes.
- Adds new test cases using random ECDSA inputs.
Reviewed Changes
Copilot reviewed 4 out of 7 changed files in this pull request and generated 2 comments.
File | Description |
---|---|
src/Nethermind/Nethermind.Precompiles.Benchmark/PrecompileBenchmarkBase.cs | Uses Path.Combine with AppContext.BaseDirectory for computing the inputs directory. |
src/Nethermind/Nethermind.Evm/Precompiles/Secp256r1Precompile.cs | Removes the manual signature verification logic and its input length check, replacing it with a call to Secp256r1.VerifySignature. |
src/Nethermind/Nethermind.Evm.Test/Secp256r1PrecompileTests.cs | Adds new test cases and a method for generating random valid signature inputs. |
src/Nethermind/Nethermind.Evm.Benchmark/StaticCallBenchmarks.cs | Updates the benchmark attribute by removing the Baseline flag. |
Files not reviewed (3)
- src/Nethermind/Benchmarks.slnx: Language not supported
- src/Nethermind/Directory.Packages.props: Language not supported
- src/Nethermind/Nethermind.Evm/Nethermind.Evm.csproj: Language not supported
Comments suppressed due to low confidence (1)
src/Nethermind/Nethermind.Evm.Benchmark/StaticCallBenchmarks.cs:122
- The removal of the Baseline attribute might affect benchmark comparisons if a reference point is needed. Confirm that this change is intentional and that performance metrics are still comparable across benchmarks.
[Benchmark]
Windows 10
Ubuntu 22 (WSL)
*Allocated doesn't take unmanaged memory into account |
Changes
Related:
Types of changes
What types of changes does your code introduce?
Testing
Requires testing
If yes, did you write tests?
Documentation
Requires documentation update
Requires explanation in Release Notes