Skip to content

Commit e938e59

Browse files
author
Antoine Riard
committed
Document our handling of announcement_sigs
We may have in the future to rebroadcast announcement_sigs at peer reconnection if this a burning issue as spec lacks a acknowledgement mechanism.
1 parent 126b514 commit e938e59

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

lightning/src/ln/channelmanager.rs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1972,6 +1972,15 @@ impl ChannelManager {
19721972
}
19731973
try_chan_entry!(self, chan.get_mut().funding_locked(&msg), channel_state, chan);
19741974
if let Some(announcement_sigs) = self.get_announcement_sigs(chan.get()) {
1975+
// If we see locking block before receiving remote funding_locked, we broadcast our
1976+
// announcement_sigs at remote funding_locked reception. If we receive remote
1977+
// funding_locked before seeing locking block, we broadcast our announcement_sigs at locking
1978+
// block connection. We should guanrantee to broadcast announcement_sigs to our peer whatever
1979+
// the order of the events but our peer may not receive it due to disconnection. The specs
1980+
// lacking an acknowledgement for announcement_sigs we may have to re-send them at peer
1981+
// connection in the future if simultaneous misses by both peers due to network/hardware
1982+
// failures is an issue. Note, to achieve its goal, only one of the announcement_sigs needs
1983+
// to be received, from then sigs are going to be flood to the whole network.
19751984
channel_state.pending_msg_events.push(events::MessageSendEvent::SendAnnouncementSignatures {
19761985
node_id: their_node_id.clone(),
19771986
msg: announcement_sigs,

0 commit comments

Comments
 (0)