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

Implemented sign_prehashed for ecdsa::Keypair and eth::Keypair #1598

Merged
merged 6 commits into from
May 24, 2024

Conversation

muraca
Copy link
Contributor

@muraca muraca commented May 20, 2024

Some people might find this useful 😄

cc @niklasad1 @jsdw thanks ❤️

@muraca muraca requested a review from a team as a code owner May 20, 2024 16:57
Copy link
Collaborator

@jsdw jsdw left a comment

Choose a reason for hiding this comment

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

Thank you! Out of interest, is this something you found yourself wanting?

I'm thinking it's probably worth adding the same to the ecdsa impl for consistency (internally both sign_prehashed fns would end up being identical but hey ho)

@muraca
Copy link
Contributor Author

muraca commented May 21, 2024

Thank you! Out of interest, is this something you found yourself wanting?

That is correct - and it's something that is often found in other similar libraries, including ethers

@muraca
Copy link
Contributor Author

muraca commented May 21, 2024

I'm thinking it's probably worth adding the same to the ecdsa impl for consistency (internally both sign_prehashed fns would end up being identical but hey ho)

You could call self.0.sign_prehashed instead of duplicating

@jsdw
Copy link
Collaborator

jsdw commented May 21, 2024

You could call self.0.sign_prehashed instead of duplicating

Yup, true! Are you up for adding that also?

@muraca
Copy link
Contributor Author

muraca commented May 21, 2024

You could call self.0.sign_prehashed instead of duplicating

Yup, true! Are you up for adding that also?

Sure, I'll do it later today

@muraca muraca changed the title Implemented sign_prehashed for eth::Keypair Implemented sign_prehashed for ecdsa::Keypair and eth::Keypair May 22, 2024
signer/src/eth.rs Outdated Show resolved Hide resolved
@muraca
Copy link
Contributor Author

muraca commented May 22, 2024

Sorry for this mess, I'm having a few issues with rust analyzer. I'll reboot my laptop and try again

@muraca muraca requested a review from jsdw May 22, 2024 09:41
@jsdw
Copy link
Collaborator

jsdw commented May 22, 2024

No worries, and thank yoU! Looking good to me now!

@jsdw jsdw merged commit ae5c092 into paritytech:master May 24, 2024
13 checks passed
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.

None yet

3 participants