Bot Protection in 10.2 and dealing with API requests
-
I currently use a nginx proxy manager and Anubis to deal with ai/bot crawling on my cloudron sites. My current Anubis config has a lot of workaround for various API paths on some apps so that Anubis doesn't try to block those requests.
I'm really interested in switching to the bot protection feature in 10.2 and remove my proxy server in front of Cloudron but I wanted to make sure I understood a couple of things first:
- Is there any built-in rules to make sure that if you enable it for a given app, paths/URLs that should not be filtered thru the bot protect mechanism are not?
- If the answer to the above is no, is there any plans to implement this or is the solution in those cases to disable bot protection completely for those apps?
- Kinda related but more of a feature request, are there any plans to allow us to set the challenge complexity per app? Git is the number one issue with crawlers and I like to always set that one to super hard but other app don't need that much protecting.
Thanks for all the hard work guys and hope you have a second to answer these questions.
-
Currently, the complexity is set for all apps. This could be changed, but in all honesty, in my tests while we've implemented this and also analyzing our git.cloudron.io for which we mainly also needed this internally, setting the complexity high rarely is the main factor, we have hardly seen any difference between a low and a high setting, either those automated ones with a real browser just sit through it or not. Presenting the/any challenge itself is the main protection in the end.
For the path exclusions, we can make this as complex as we want. Initially we also aimed for complex rule sets like anubis has, but since the current approach fends of most of the things the micromanaging at least for us was not worth it. Especially since any app update can change app behavior and app paths, breaking things silently.
However this is mostly driven by our experience and usage, so maybe firstly can you explain in a bit more detail who those custom filters for you look like and what they aim to help with, then we can see what we can add. The current implementation is just the bare minimum on Cloudron side, just to keep apps like our gitlab online.
-
Thank you for you reply.
Currently I have rules setup for things like api paths (
^/api/), Mastodon (^/users/[^/]+(/.*)?$,^/packs/[^/]+(/.*)?,^/tags/[^/]+(/.*)?$,^/manifest,^/inbox), BitWarden (^/identity/,^/notifications/) but also basic internet things like allowing well-known, favicon, robots.txt, etc.. and also a rule to allow downloading a release package from my forgejo server via wget (I have a script that uses this to install software).So what I was wondering was, how does the Cloudron bot protection deal with things like this? Would these all break if I was to enable it on those sites?
Thanks.
-
This depends a bit on who accesses those paths. Note that Cloudron bot protection (just like anubis) actually only serves up challenges for bots who identify as real browsers. This means curl/wget/... agents will be let through just fine. At least to me this was counter intiuitive, as I thought most bots would act like curl, but actually most bots who cause harm are actually the ones who want to look like a browser. This may change over time of course, but when the ecosystem of bot farms change, we can then introduce a http refresh challenge for non-browser bots.
Maybe that sheds some light on the topic.
Also note that normal crawlers from search engines for example will just be let through. Unexpectedly in our tests those all behave well and even identify themselves with their correct user-agents.
-
Ok I'm going to bypass my npm server for some apps and enable the bot protection to start experimenting. So far I can confirm that Nextcloud and Synapse don't work correctly with bot protection on. I'll update this thread with more findings as I go along.
-
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login