This PR introduces the creation of Bitcoin moving funds transaction which allows funds to be transferred between source wallet and target wallets.
The creation of the Bitcoin moving funds transaction is the responsibility of movingFundsAction which is executed
after moving funds commitment has been submitted.
Executing the movingFundsAction consists of several steps:
initial validation of the moving funds proposal against the Ethereum network
waiting 32 Ethereum blocks to ensure the commitment transaction has permanently entered the blockchain and will not be removed by a chain reorganisation
final validation of the moving funds proposal against the Ethereum network which is needed to ensure the commitment was not changed during waiting
assembling the moving funds Bitcoin transaction
signing the moving funds Bitcoin transaction
broadcasting the moving funds Bitcoin transaction
The moving funds Bitcoin transaction consists of one input (main wallet UTXO of the source wallet) and one or more outputs (one output for each target wallet). The outputs are all P2WPKH.
The three moving funds transactions used in tests were actually broadcasted within the Bitcoin testnet network to get the final confirmation that the transactions were correctly contructed.
Refs: https://github.com/keep-network/keep-core/issues/3734.
This PR introduces the creation of Bitcoin moving funds transaction which allows funds to be transferred between source wallet and target wallets.
The creation of the Bitcoin moving funds transaction is the responsibility of
movingFundsAction
which is executed after moving funds commitment has been submitted. Executing themovingFundsAction
consists of several steps:32
Ethereum blocks to ensure the commitment transaction has permanently entered the blockchain and will not be removed by a chain reorganisationThe moving funds Bitcoin transaction consists of one input (main wallet UTXO of the source wallet) and one or more outputs (one output for each target wallet). The outputs are all P2WPKH.
The three moving funds transactions used in tests were actually broadcasted within the Bitcoin testnet network to get the final confirmation that the transactions were correctly contructed.