Allow repeaters to restrict Flooded REQ, ANON_REQ, and RESPONSE packets#2797
Open
netprince17 wants to merge 1 commit into
Open
Allow repeaters to restrict Flooded REQ, ANON_REQ, and RESPONSE packets#2797netprince17 wants to merge 1 commit into
netprince17 wants to merge 1 commit into
Conversation
…ood response packets by the number of hops.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
In our meshcore region, we are receiving a large number of flooded request, flooded anonymous request, and flooded response packets. We think this is probably from people using automation which is not quite configured properly. There are more flooded anonymous request and flooded response packets than flooded advertisement packets. I have monitored the packets using the 'Rx Log' tool, as well as using the pyMC:Console.
This patch allows the repeater owner to configure a maximum number of hops for flooded request, flooded anonymous request, and flooded response packets using the CLI.
set flood.max.response 8
set flood.max.request 8
set flood.max.anon.request 8
All options default to 64, so no changes to the default repeater behavior.
This patch was modeled after the recent flood.max.advert addition to meshcore found here:
74adda6
I have been testing this patch for several days on two repeaters. Using the test repeaters, I can still log-in to further away repeaters, less than the configured 8 hops away.
Dropping these packets will likely prevent logging-in to repeaters/rooms that are further away than the configured hops. There may be other consequences of preventing flooded request, anon request, and response packets further away than the configured hops, but I have not found any other downside yet.