-
Notifications
You must be signed in to change notification settings - Fork 18
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
fix: update second_sign method to use schnorr #106
Conversation
Thanks for submitting this pull request! A maintainer will review this in the next few days and explicitly select labels so you know what's going on. If no reviewer appears after a week, a reminder will be sent out. |
Can you add a test that includes the second signature so this gets caught in any future versions? Just for transfer will suffice for now. |
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.
additionally, it requires a fix in transactions/serializer.py
. You'll have to change elif self.transaction.get('signSignature'):
to if not skip_second_signature and self.transaction.get('signSignature'):
crypto/transactions/transaction.py
Outdated
@@ -162,6 +162,16 @@ def verify_schnorr(self): | |||
|
|||
return is_valid | |||
|
|||
def verify_schnorr_secondsig(self): |
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.
requires a secondPublicKey
parameter
After that you can add a tests in |
@ItsANameToo I made all the changes suggested and added the extra test. Feel free to re-review. |
All updated. I think this is ready now. |
A member has approved this PR. A maintainer will merge this PR shortly. If it shouldn't be merged yet, please leave a comment saying so and we'll wait. Thank you for your contribution! |
Your pull request has been merged and marked as tier 4. It will earn you $20 USD. |
Summary
Update the second sign function to use Schnorr
The current code is broken. First sign is Schnorr and second sign was ECSDA which led transactions having issues being verified since they were not correct
Updated a single function in base.py
Checklist