1
0
mirror of https://github.com/lightning/bolts.git synced 2024-11-19 01:50:03 +01:00

must not filter local gossip

We should never filter out `channel_update`s for channels with our direct peer (even if it hasn't set a `gossip_timestamp_filter`), otherwise we wouldn't be able to use the channels for sending or relaying outgoing payments.
This commit is contained in:
Pierre-Marie Padiou 2019-03-29 15:41:12 +01:00 committed by GitHub
parent da71867c84
commit feb6cada87
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -681,7 +681,7 @@ which overlaps the ranges of the request.
This message allows a node to constrain future gossip messages to This message allows a node to constrain future gossip messages to
a specific range. A node which wants any gossip messages would have a specific range. A node which wants any gossip messages would have
to send this, otherwise `gossip_queries` negotiation means no gossip to send this, otherwise `gossip_queries` negotiation means no gossip
messages would be received. messages would be received.
Note that this filter replaces any previous one, so it can be used Note that this filter replaces any previous one, so it can be used
multiple times to change the gossip from a peer. multiple times to change the gossip from a peer.
@ -700,6 +700,7 @@ The receiver:
- SHOULD restrict future gossip messages to those whose `timestamp` - SHOULD restrict future gossip messages to those whose `timestamp`
is greater or equal to `first_timestamp`, and less than is greater or equal to `first_timestamp`, and less than
`first_timestamp` plus `timestamp_range`. `first_timestamp` plus `timestamp_range`.
- MUST NOT restrict gossip about channels to the sender
- If a `channel_announcement` has no corresponding `channel_update`s: - If a `channel_announcement` has no corresponding `channel_update`s:
- MUST NOT send the `channel_announcement`. - MUST NOT send the `channel_announcement`.
- Otherwise: - Otherwise:
@ -724,6 +725,8 @@ is simple to implement.
In the case where the `channel_announcement` is nonetheless missed, In the case where the `channel_announcement` is nonetheless missed,
`query_short_channel_ids` can be used to retrieve it. `query_short_channel_ids` can be used to retrieve it.
## Initial Sync ## Initial Sync
If a node requires an initial sync of gossip messages, it will be flagged If a node requires an initial sync of gossip messages, it will be flagged