If you want to humor me a bit, as I'd be curious to see how well the mass-scrapers perform against the Anubis WAF. Even against your load tester, I'd be curious. The botnets seemed to have largely given up on my stuff unless it's a new wave of 'em - then they give up again.They're just looking for creative ways to thwart your efforts.Don't panic... they'll be back. That test forum, 3 days now, and I just looked at the homepage and it has 1000 online. I think my main site has about 30k online at the moment, but its fine, barely doing much at that level.
These bots are ferocious to say the least. Persistent too.
Pre-reqs & Details: https://anubis.techaro.lol/docs/developer/building-anubis/
Code:
git clone https://github.com/TecharoHQ/anubis && cd anubis
make deps && make assets && make build
/etc/anubis/instance-yourwebsite.env
Code:
BIND_NETWORK=tcp
BIND=0.0.0.0:8923
TARGET=http://your-backend-server-ip:80
POLICY_FNAME=/etc/anubis/policy/botPolicies.yaml
CUSTOM_REAL_IP_HEADER=X-Real-IP
COOKIE_DOMAIN=.yourdomainname.tld
COOKIE_EXPIRATION_TIME=504h
COOKIE_PREFIX=botcheck
COOKIE_SECURE=true
METRICS_BIND=0.0.0.0:9923
METRICS_BIND_NETWORK=tcp
WEBMASTER_EMAIL=some@random-email-address.tld
versionFlag=false
ED25519_PRIVATE_KEY_HEX_FILE=/etc/anubis/key.hex
openssl rand -hex 32/etc/anubis/policy/botPolicies.yaml
YAML:
bots:
- import: /etc/anubis/crawlers/_allow-good.yaml
- name: public-paths
action: ALLOW
path_regex: ^/(?:\.well-known/.*|favicon\.ico|robots\.txt)$
- name: lan-whitelist
action: ALLOW
remote_addresses:
- 192.168.20.0/22
- 10.64.0.0/22
- name: challenge-all
action: CHALLENGE
path_regex: .*
challenge:
algorithm: fast
difficulty: 5
store:
backend: valkey
parameters:
url: "redis://your-redis-server-ip:6379/42"
You can monitor client pass:fails in the redis DB server of your choosing.
METRICS_BIND is prometheus supported/connectable. difficulty: 5 is the be-all-end-all check. 0 - no check, 4 - normal quick check, 5 - gets slower, but blocks most bots and then 6+, becomes hell-difficulty, 15 is impossible.






