Skip to content

DHT infinite packet spam to offline peers #1973

@JFreegman

Description

@JFreegman

If the DHT doesn't have a minimum number of peers it will spam a list of previously seen peers, trying to connect with them seemingly forever, until it fills all of its online peer slots. This mechanism makes sense when trying to bootstrap on initialization, or after a network outage. However, on very small networks, what you end up with is a lot of unsolicited network traffic to IP addresses that were once but are no longer part of the DHT. Furthermore, this spam persists even if the sender restarts the client, as the offline nodes are saved.

This is not only a big waste of bandwidth on the sender's part, but it's also annoying on the receiver's part, since their network logs get filled with inbound tox packets. But like I said, it only happens on small networks where there are fewer total nodes than there are peer slots. So my question is, is it worth worrying about? If so, how should it best be handled?

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Low prioritybugBug fix for the user, not a fix to a build scriptnetworkNetwork

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions