You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are using a Counting Bloom Filter to count IPs sending wrong
connections IDs. IPs are banned after sending 10 wrong connections IDs.
CBFs are fast and use litle memory but they are also innaccurate. They
have False Positives meaning some IPs would be banned only becuase there
are bucket colissions (IPs sharing the same counter).
To avoid banning IPs incorrectly we decided to introduce a second
counter, which is a HashMap counting error is a exact way. IPs are only
banned when this counter reaches the limit.
We keep the CBF as a first level filter. It's a fast check to filter IPs
without affecting tracker's performance. When the IP is banned according
tho the first filter we start a counter for that IP in the second
exact counter.
This solution should be good if the number of IPs is low. We have to
find another solution anyway for IPv6 where is cheaper to own a range if
IPs.
0 commit comments