]> git.bitcoin.ninja Git - rust-lightning/commit
Move checking of specific require peer feature bits to handlers
authorMatt Corallo <git@bluematt.me>
Mon, 12 Sep 2022 19:06:17 +0000 (19:06 +0000)
committerMatt Corallo <git@bluematt.me>
Tue, 13 Sep 2022 16:59:30 +0000 (16:59 +0000)
commitbbb590b5518eb6e76ddd642187163c487c67dd5c
tree2e8ee7e177cbb763ad614f42b59f3b6c95b792d6
parent29484d8e2c97996773bf4bcb1c0238f6d9a63d42
Move checking of specific require peer feature bits to handlers

As we remove the concept of a global "known/supported" feature set
in LDK, we should also remove the concept of a global "required"
feature set. This does so by moving the checks for specific
required features into handlers.

Specifically, it allows the handler `peer_connected` method to
return an `Err` if the peer should be disconnected. Only one such
required feature bit is currently set - `static_remote_key`, which
is required in `ChannelManager`.
lightning-net-tokio/src/lib.rs
lightning/src/ln/channelmanager.rs
lightning/src/ln/msgs.rs
lightning/src/ln/onion_route_tests.rs
lightning/src/ln/peer_handler.rs
lightning/src/onion_message/messenger.rs
lightning/src/routing/gossip.rs
lightning/src/util/test_utils.rs