mirror of
https://github.com/aljazceru/lightning.git
synced 2026-02-08 23:54:20 +01:00
hsmd: Added fields to hsm_sign_remote_commitment_tx to allow complete validation.
Changelog-Added: hsmd: Added fields to hsm_sign_remote_commitment_tx to allow complete validation by signing daemon.
This commit is contained in:
@@ -175,6 +175,11 @@ struct bitcoin_tx *initial_commit_tx(const tal_t *ctx,
|
||||
int pos = bitcoin_tx_add_output(
|
||||
tx, scriptpubkey_p2wsh(tx, wscript), amount);
|
||||
assert(pos == n);
|
||||
tx->output_witscripts[n] =
|
||||
tal(tx->output_witscripts, struct witscript);
|
||||
tx->output_witscripts[n]->ptr =
|
||||
tal_dup_arr(tx->output_witscripts[n], u8,
|
||||
wscript, tal_count(wscript), 0);
|
||||
n++;
|
||||
}
|
||||
|
||||
@@ -202,6 +207,8 @@ struct bitcoin_tx *initial_commit_tx(const tal_t *ctx,
|
||||
|
||||
assert(n <= tx->wtx->num_outputs);
|
||||
|
||||
tal_resize(&(tx->output_witscripts), n);
|
||||
|
||||
/* BOLT #3:
|
||||
*
|
||||
* 7. Sort the outputs into [BIP 69+CLTV
|
||||
|
||||
Reference in New Issue
Block a user