Skip to content

Conversation

@sdaftuar
Copy link
Member

@sdaftuar sdaftuar commented Aug 7, 2020

Backport of #19620 to 0.19.

@sdaftuar sdaftuar force-pushed the 2020-08-reject-unknown-wit-0.19 branch from e44f406 to a77c784 Compare August 7, 2020 16:44
@sdaftuar sdaftuar force-pushed the 2020-08-reject-unknown-wit-0.19 branch 2 times, most recently from 127331e to d670580 Compare August 7, 2020 17:36
@laanwj
Copy link
Member

laanwj commented Aug 9, 2020

As for the appveyor error I'm not sure I think you either need fae0e93 (#19444) and/or faf5e25 (#18640).

@sdaftuar sdaftuar force-pushed the 2020-08-reject-unknown-wit-0.19 branch from d670580 to 568007c Compare August 10, 2020 17:37
@sdaftuar
Copy link
Member Author

Just tried to backport #19444 but not sure I did it right...

@jnewbery
Copy link
Contributor

We should merge #19025 rather than include appveyor changes in this PR.

@jnewbery
Copy link
Contributor

utACK the last two commits in 568007cffe0c3998d5b4b20e16d4ae6fb779ed43

sdaftuar and others added 2 commits August 11, 2020 10:27
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
@instagibbs
Copy link
Member

utACK 52c3bec

@maflcko maflcko added this to the 0.19.2 milestone Aug 24, 2020
@jnewbery
Copy link
Contributor

utACK 52c3bec

Copy link
Contributor

@jonasschnelli jonasschnelli left a comment

Choose a reason for hiding this comment

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

utACK 52c3bec
Compared with #19620

@jonasschnelli jonasschnelli merged commit aee9d23 into bitcoin:0.19 Aug 28, 2020
MarkLTZ added a commit to litecoinz-core/litecoinz that referenced this pull request Nov 8, 2020
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Feb 15, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants