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

Util: Remove signature module in favor of direct ethereum-cryptography usage (needs analysis) #1845

Open
holgerd77 opened this issue Apr 7, 2022 · 1 comment

Comments

@holgerd77
Copy link
Member

Similar to #1844 the signature functionality is now also provided by ethereum-cryptography.

Particularly for current state (so: typed, e.g. EIP-2930 txs) tx signature handling this functionality can be used very much directly, which becomes the very prevalent use case.

It should therfore be analyzed (and then executed upon) if the signature module can also be removed from Util in favor of a direct usage. One way to deal with the remaining legacy EIP-155 code in the signature module would be to encapsulate this code in the legacy tx class being the only remaining consumer (would need some confirmation).

Note that this issue should bre handled with special care due to the sensitive nature of the signature functionality.

Main functionality is contained in ecsign() and ecrecover().

These functions are - beside tx - also used in:

  • ecsign(): Block Header Clique Functionality
  • ecrecover(): Block Header Clique Functionality
  • ecrecover(): VM precompile

Not sure if I missed something. Also not sure yet if or if not legacy signing functionality is used in some of these and how these usages would be handled on a direct ethereum-cryptography usage.

@holgerd77
Copy link
Member Author

Some update on this: decided to be downgraded in favor of some v5 included work to ease the Util signature-related function usage along typed txs - see #1904 - as well as some additional refactoring work for v6 done here #1945.

Still to be decided if there will be an additional complete deprecation of the code during the v6 lifecycle.

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

No branches or pull requests

2 participants