Skip to content

Commit

Permalink
openingd: tell them channel_type if signature is bad.
Browse files Browse the repository at this point in the history
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
  • Loading branch information
rustyrussell committed Sep 9, 2021
1 parent 6730417 commit e493c25
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions openingd/openingd.c
Original file line number Diff line number Diff line change
Expand Up @@ -708,12 +708,14 @@ static bool funder_finalize_channel_setup(struct state *state,

if (!check_tx_sig(*tx, 0, NULL, wscript, &state->their_funding_pubkey, sig)) {
peer_failed_err(state->pps, &state->channel_id,
"Bad signature %s on tx %s using key %s",
"Bad signature %s on tx %s using key %s (channel_type=%s)",
type_to_string(tmpctx, struct bitcoin_signature,
sig),
type_to_string(tmpctx, struct bitcoin_tx, *tx),
type_to_string(tmpctx, struct pubkey,
&state->their_funding_pubkey));
&state->their_funding_pubkey),
fmt_featurebits(tmpctx,
state->channel->type->features));
}

/* We save their sig to our first commitment tx */
Expand Down

0 comments on commit e493c25

Please sign in to comment.