HomePhabricator

[Consensus] Allow only tx versions 1 and 2 by consensus

Description

[Consensus] Allow only tx versions 1 and 2 by consensus

Summary:
After the Wellington upgrade, we disallow txs that don't have nVersion set to 1 or 2.

This is already a policy rule, therefore doesn't require changes by any wallet.

Forbidding the version field from having an arbitrary value (even if just for miners) allows us to use this field for a new transaction format, e.g. Mitra.

The Bitcoin Cash chain is doing the exact same upgrade, for more in-depth analysis (including which non-1-2 transaction versions have historically been mined already), you can read their CHIP.

Inspired by bchn#1599.

Test Plan: Run the entire CI pipeline

Reviewers: Fabien, #bitcoin_abc, sdulfari

Reviewed By: Fabien, #bitcoin_abc, sdulfari

Subscribers: sdulfari

Differential Revision: https://reviews.bitcoinabc.org/D13159

Details

Provenance
tobias_ruckAuthored on Feb 22 2023, 14:25
teamcityPushed on Feb 27 2023, 18:25
Parents
rSTAGING22b5f24f5d16: Fix randomly failing scheduler_tests test
Branches
Unknown
Tags
Unknown
References
tag: phabricator/base/38086

Event Timeline