How to massively ban a pool of @ip?
Hello, I'm having an issue on several servers. Sometimes there's a high load caused by a pool of IP addresses making massive requests (lots of bots). The problem is that CrowdSec doesn't ban them because it's one IP at a time. Do you have a solution for this?
14 Replies
Important Information
This post has been marked as resolved. If this is a mistake please press the red button below or type
/unresolve
© Created By WhyAydan for CrowdSec ❤️
Depends is there an identifier you can use to group these together?
Here is an example of using bytedance spider to ban a range
but obviously this depends if your using a remediation that supports ranges
I have IP pools starting with 47.79 or 47.82, for example, and user-agents like PetalBot or SemrushBot, for example.
but are using a hard remediation like a firewall cause if not they will still cause load
yes i have
nd is it nftables or iptables or pf if your using a BSD based one?
I'm using iptables
sweet so it supports ranges, so you can adapt the example I gave and maybe narrow down the
/24
range to be smaller and my advice is created a profile to issue a short term ban like 30 minutes.I'll test it like this for now.
just note the default profile will issue a
4hr
ban on the range, so I advise to make a custom profile above all to issue a short term ban as you might catch alot of people 😄Oh yes, you're absolutely right.
like this ?
Yes!, just make sure its above the default remeidation for ranges and it will catch them 👍
right
thx for yr help
Resolving How to massively ban a pool of @ip?
This has now been resolved. If you think this is a mistake please run
/unresolve