-
Notifications
You must be signed in to change notification settings - Fork 38.8k
[0.17][psbt] always drop the unnecessary utxo and convert non-witness utxo to witness when necessary #14196
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…wallet things Instead of dropping the unnecessary UTXO based on whether the wallet did something, do it based on whether two UTXOs are there.
If a witness signature was created when a non-witness UTXO is used, convert the non-witness UTXO to a witness one.
feddbe7 to
fcefc68
Compare
Member
|
Test failure seemed unrelated, rebooted Travis. |
Contributor
|
This sounds right to me. |
Contributor
|
ACK |
|
Would it be possible to add a test for this? |
Member
|
Moved to 0.17.1 for now, because this can be worked around and psbt isn't considered final in the 0.17.0 release. |
laanwj
added a commit
that referenced
this pull request
Nov 1, 2018
…sig created 862d159 Add test for conversion from non-witness to witness UTXO (Pieter Wuille) f8c1714 Convert non-witness UTXOs to witness if witness sig created (Andrew Chow) Pull request description: If a witness signature was created when a non-witness UTXO is used, convert the non-witness UTXO to a witness one. Port of #14196 to master. Tree-SHA512: 2235eeb008ffa48e821628032d689e4a83bff6c29b93fa050ab2ee492b0e67b3a30f29a680d4a0e574e05c3a2f9edf0005e161fbe25b7aef2acd034a2424e2f2
Contributor
|
utACK fcefc68 |
Member
|
utACK fcefc68 |
maflcko
pushed a commit
that referenced
this pull request
Dec 1, 2018
…rt non-witness utxo to witness when necessary fcefc68 Convert non-witness UTXOs to witness if witness sig created (Andrew Chow) fcdea8a Drop the unnecessary UTXO based on the UTXOs present, not on earlier wallet things (Andrew Chow) Pull request description: When we sign an input in a psbt that has a non-witness utxo but a witness signature is produced, we will now replace the non-witness utxo with the corresponding witness utxo. Furthermore, we should make sure that the correct UTXO type is used based on what UTXOs are there, not based on earlier wallet behavior. Note that this is PR'd to the 0.17 branch because the code here no longer exists in master. Tree-SHA512: 882e9e4e9b77d6ac1743c35c0d59023aad6f4f19193398f97f2c6b81f6627d74e5220b1d674a0edba1ff2fc2a7f61afbf838d3faf0a964fccd3dee97c631aa47
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When we sign an input in a psbt that has a non-witness utxo but a witness signature is produced, we will now replace the non-witness utxo with the corresponding witness utxo. Furthermore, we should make sure that the correct UTXO type is used based on what UTXOs are there, not based on earlier wallet behavior.
Note that this is PR'd to the 0.17 branch because the code here no longer exists in master.