From 6bc71796c86b15d6ae647e90fdf450f1e05b2fa7 Mon Sep 17 00:00:00 2001 From: Christian Decker Date: Thu, 17 Aug 2023 18:23:26 +0200 Subject: [PATCH] openingd: Tentatively accept zeroconf when proposed We then still use our own minimum_depth to enforce our security. There is no harm in accepting theirs --- openingd/openingd.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/openingd/openingd.c b/openingd/openingd.c index dcf18340b..801d272b0 100644 --- a/openingd/openingd.c +++ b/openingd/openingd.c @@ -965,12 +965,16 @@ static u8 *fundee_channel(struct state *state, const u8 *open_channel_msg) */ if (open_tlvs->channel_type) { open_channel_had_channel_type = true; + /* Tentatively accept OPT_ZEROCONF. We'll check + * further down again. This is required because we + * haven't talked to the openchannel hook at this + * point. */ state->channel_type = channel_type_accept(state, open_tlvs->channel_type, state->our_features, state->their_features, - state->minimum_depth == 0); + true); if (!state->channel_type) { negotiation_failed(state, "Did not support channel_type %s",