From ae1673172b5c39b35348cfb9caa605875891fb73 Mon Sep 17 00:00:00 2001 From: Matt Corallo Date: Mon, 4 May 2020 13:56:53 -0400 Subject: [PATCH] f note why we use a dummy pubkey as req by antoine --- lightning/src/ln/channel.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lightning/src/ln/channel.rs b/lightning/src/ln/channel.rs index 7a483ae14..879cb9f8b 100644 --- a/lightning/src/ln/channel.rs +++ b/lightning/src/ln/channel.rs @@ -3459,6 +3459,9 @@ impl Channel { pub fn get_channel_reestablish(&self) -> msgs::ChannelReestablish { assert_eq!(self.channel_state & ChannelState::PeerDisconnected as u32, ChannelState::PeerDisconnected as u32); assert_ne!(self.cur_remote_commitment_transaction_number, INITIAL_COMMITMENT_NUMBER); + // Prior to static_remotekey, my_current_per_commitment_point was critical to claiming + // current to_remote balances. However, it no longer has any use, and thus is now simply + // set to a dummy (but valid, as required by the spec) public key. // fuzztarget mode marks a subset of pubkeys as invalid so that we can hit "invalid pubkey" // branches, but we unwrap it below, so we arbitrarily select a dummy pubkey which is both // valid, and valid in fuzztarget mode's arbitrary validity criteria: -- 2.39.5