kad: remove default IPFS DHT protocol name #5006
Labels
difficulty:easy
getting-started
Issues that can be tackled if you don't know the internals of libp2p very well
help wanted
Milestone
Today a new
kad::Config
will use the protocol name of the IPFS DHT, namely/ipfs/kad/1.0.0
, by default.This is problematic in the case where one wants to connect to a different DHT instance, or launch their own. E.g. in the past, new DHT networks have accidentally merged with the IPFS DHT instance.
To prevent this from happening in the future, we should not provide a default protocol name, but instead require a user to explicitly specify the protocol name and thus the DHT instance that they would like to join.
One possible fix would be to introduce
libp2p_kad::Config::new
taking a protocol name and to remove theDefault
implementation onlibp2p_kad::Config
.rust-libp2p/protocols/kad/src/behaviour.rs
Lines 168 to 202 in 305e02c
The text was updated successfully, but these errors were encountered: