-
Notifications
You must be signed in to change notification settings - Fork 38.7k
0.19: Add txids with non-standard inputs to reject filter #19681
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
jonasschnelli
merged 2 commits into
bitcoin:0.19
from
sdaftuar:2020-08-reject-unknown-wit-0.19
Aug 28, 2020
Merged
0.19: Add txids with non-standard inputs to reject filter #19681
jonasschnelli
merged 2 commits into
bitcoin:0.19
from
sdaftuar:2020-08-reject-unknown-wit-0.19
Aug 28, 2020
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
e44f406 to
a77c784
Compare
127331e to
d670580
Compare
Member
d670580 to
568007c
Compare
Member
Author
|
Just tried to backport #19444 but not sure I did it right... |
Contributor
|
We should merge #19025 rather than include appveyor changes in this PR. |
Contributor
|
utACK the last two commits in 568007cffe0c3998d5b4b20e16d4ae6fb779ed43 |
Our policy checks for non-standard inputs depend only on the non-witness portion of a transaction: we look up the scriptPubKey of the input being spent from our UTXO set (which is covered by the input txid), and the p2sh checks only rely on the scriptSig portion of the input. Consequently it's safe to add txids of transactions that fail these checks to the reject filter, as the witness is irrelevant to the failure. This is helpful for any situation where we might request the transaction again via txid (either from txid-relay peers, or if we might fetch the transaction via txid due to parent-fetching of orphans). Further, in preparation for future witness versions being deployed on the network, ensure that WITNESS_UNKNOWN transactions are rejected in AreInputsStandard(), so that transactions spending v1 (or greater) witness outputs will fall into this category of having their txid added to the reject filter. Github-Pull: bitcoin#19620 Rebased-From: 7989901
Github-Pull: bitcoin#19620 Rebased-From: 9f88ded
568007c to
52c3bec
Compare
Member
|
utACK 52c3bec |
Contributor
|
utACK 52c3bec |
jonasschnelli
approved these changes
Aug 28, 2020
Contributor
jonasschnelli
left a comment
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.
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.
Backport of #19620 to 0.19.