-
-
Notifications
You must be signed in to change notification settings - Fork 669
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
Trezor's RFC6979 operation diverges from that of Bitcoin core #2085
Comments
I am for changing the behaviour in our library as well to match libsecp256k1. @onvej-sl can you please have a look what needs to be changed in our rfc6979 code to match the new behaviour? The change in libsecp256k1 was this commit: bitcoin-core/secp256k1@45f37b6 |
This branch should fix this issue. What still needs to be done is to fix tests, see Andrew's comments in #2089. |
There seem to be some issues with the indentation now, that is probably not the original issue Does the tests issue somehow involve the |
When I run the tests locally (after fixing the indentation), I have one failure:
|
Sorry for that. It seems to me that I committed an unfinished work. d3f5c59 fixes it.
This issue is not directly related to the scriptPubKey check. |
In the latest |
@onvej-sl if you are happy with the changes, will you please squash the fixup commits and create a PR so we can review and merge this? |
Definitely. Since signatures of some transactions were changed, the transactions don't correspond to the transactions on blockchain that are referenced in comments (see this). We probably need to create new transactions on blockchain for the tests that I modified. I was hoping it is something @grdddj has more experience with. |
Yes, seems like new blockchain transactions will be needed. We could also use the newly-created I am not sure how to do Before I would do this, could we have a short meeting to discuss it? |
@onvej-sl |
@onvej-sl anything that needs to be tested on our side or I can move it from Needs QA section ? |
There is no need to test anything, thanks. I set the status to "Approved". |
Bitcoin recently merged a PR which changes the RFC6979 logic slightly: bitcoin-core/secp256k1#1064
This change manifested during differential fuzzing of both libraries. Here's an example input/output:
cleartext
denotes the input message that is passed unhashed toecdsa_sign()
.Is this something you would like to address? If not that's fine, but I need to know so I can change my fuzzer logic not to abort on RFC6979 differences between Trezor and Bitcoin.
The text was updated successfully, but these errors were encountered: