Skip to content
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

EC Recover #3696

Open
wants to merge 14 commits into
base: master
Choose a base branch
from
Open

EC Recover #3696

wants to merge 14 commits into from

Conversation

shargon
Copy link
Member

@shargon shargon commented Jan 24, 2025

Description

Close #3628
Alternative to #3633

Type of change

  • Optimization (the change is only an optimization)
  • Style (the change is only a code style for better maintenance or standard purpose)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

  • Crypto tests

Test Configuration:

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

@shargon shargon mentioned this pull request Jan 24, 2025
15 tasks
@shargon shargon marked this pull request as ready for review January 24, 2025 09:12
@shargon
Copy link
Member Author

shargon commented Jan 24, 2025

@neo-project/core Please take special look into HashAlgorithm.None I think that is well implemented and it can't produce a state difference in other places

@shargon shargon requested a review from Jim8y January 26, 2025 10:11

var recoveredKey2 = Crypto.ECRecover(signature2, messageHash2);
CollectionAssert.AreEqual(expectedPubKey1, recoveredKey2.EncodePoint(true));
Assert.IsTrue(Crypto.VerifySignature(message2, signature2, recoveredKey2, Neo.Cryptography.HashAlgorithm.Keccak256));
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Jim8y this line fault, could you help me?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ping @Jim8y

@shargon shargon added the Help Wanted We suggest a careful read at https://docs.neo.org/. However, fell free to further discuss the topic. label Feb 11, 2025
@shargon shargon requested a review from Jim8y February 11, 2025 11:50
@Jim8y Jim8y self-assigned this Feb 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Hardfork Help Wanted We suggest a careful read at https://docs.neo.org/. However, fell free to further discuss the topic. Waiting for Review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Recover Public Key from Signature for Secp256k1
3 participants