mirror of
https://github.com/Retropex/bitcoin.git
synced 2025-05-21 09:32:39 +02:00
Label and allow overriding bad-witness-anchor-not-empty rejections
This commit is contained in:
parent
a25c4629a8
commit
a1df69392d
@ -263,7 +263,7 @@ bool IsWitnessStandard(const CTransaction& tx, const CCoinsViewCache& mapInputs,
|
|||||||
|
|
||||||
// witness stuffing detected
|
// witness stuffing detected
|
||||||
if (prevScript.IsPayToAnchor()) {
|
if (prevScript.IsPayToAnchor()) {
|
||||||
return false;
|
MaybeReject("anchor-not-empty");
|
||||||
}
|
}
|
||||||
|
|
||||||
bool p2sh = false;
|
bool p2sh = false;
|
||||||
|
@ -405,7 +405,7 @@ class MempoolAcceptanceTest(BitcoinTestFramework):
|
|||||||
anchor_nonempty_wit_spend.rehash()
|
anchor_nonempty_wit_spend.rehash()
|
||||||
|
|
||||||
self.check_mempool_result(
|
self.check_mempool_result(
|
||||||
result_expected=[{'txid': anchor_nonempty_wit_spend.rehash(), 'allowed': False, 'reject-reason': 'bad-witness-nonstandard'}],
|
result_expected=[{'txid': anchor_nonempty_wit_spend.rehash(), 'allowed': False, 'reject-reason': 'bad-witness-anchor-not-empty'}],
|
||||||
rawtxs=[anchor_nonempty_wit_spend.serialize().hex()],
|
rawtxs=[anchor_nonempty_wit_spend.serialize().hex()],
|
||||||
maxfeerate=0,
|
maxfeerate=0,
|
||||||
)
|
)
|
||||||
|
Loading…
Reference in New Issue
Block a user