I personally use nginx-ultimate-bad-bot-blocker but also custom IP ranges (the entirety of Israel plus GAFAM), and fail2ban.

I saw a dramatic drop in scraper-related traffic, although I still have some offenders trying to access (and failing in doing so).

Which solution do you use?

  • GreenKnight23@lemmy.world
    link
    fedilink
    English
    arrow-up
    6
    ·
    4 hours ago

    personally I enjoy utilizing my local LLM to generate garbage content at a continuous rate while piping it into the response to their LLM. it’s just garbage enough to poison their data but not garbage enough to set off any flags.

    1000004994

    • cmeerw@programming.dev
      link
      fedilink
      English
      arrow-up
      2
      ·
      36 minutes ago

      it’s just garbage enough to poison their data but not garbage enough to set off any flags.

      How would you know?

      • GreenKnight23@lemmy.world
        link
        fedilink
        English
        arrow-up
        1
        ·
        1 minute ago

        two reasons

        1. they keep eating my endless stream of shit no matter how many gigs it slops out
        2. they keep coming back to the hose that spews shit out

        if they didn’t finish eating their slop, it would mean it’s too sloppy.

        if they didn’t come back for seconds, it would mean the training found the slop too shitty.

        either way. they keep coming back, and I’ll keep slopping shit into their datasets.

  • hperrin@lemmy.ca
    link
    fedilink
    English
    arrow-up
    19
    ·
    2 days ago

    I use Anubis. I’ve been impressed with it so far. I attempted to get an LLM to access it, and it gave up, so I consider that a win.

    • Carl@anarchist.nexus
      link
      fedilink
      English
      arrow-up
      4
      ·
      1 day ago

      I’ve considered something like this, but setting it up always ends with like 47 tabs open for different terms and acronyms I don’t know.

  • JustTesting@lemmy.hogru.ch
    link
    fedilink
    English
    arrow-up
    15
    ·
    1 day ago

    anything visiting specific subpages without a reasonable referer is banned

    the login page is whitelisted, anything without a 200 from from login is banned if trying to access other parts (since i only care about logged in users on that app anyways)

    anything in the abuseip list is proactively banned

    certain datacenter ip ranges are blocked wholesale

    too many errors -> ban

    iocaine to make them lost in fake pages based on heuristics like user agent

    honeypot link to the iocaine maze that a regular user wont see

    ratelimits and accompanying bans if exceeded

    blacklist of user agents

    geoip banning

    had to switch to nftables to support the volume of banned ips, iptables would buckle under the load.

    • DarkCloud@lemmy.world
      link
      fedilink
      English
      arrow-up
      3
      ·
      1 day ago

      anything visiting specific subpages without a reasonable referer is banned

      I’m a passer by, won’t that capture people who paste links?

      • JustTesting@lemmy.hogru.ch
        link
        fedilink
        English
        arrow-up
        1
        ·
        22 hours ago

        It depends on the page. Like no normal user will bookmark or paste a /login url. The only time a user ends up there is when pressing the login button or when they were accidentaly logged out. So it’s a pretty reliable signal. And there’s usualls a lot of pages a user will not go to directly. Like who bookmarks a TOS page?

        • dropdrip@lemmy.ml
          link
          fedilink
          English
          arrow-up
          6
          ·
          14 hours ago

          This has been an issue for me–people making assumptions about how normal users operate their computers. Their is a norm, but by blocking deviations you’re just blocked those that deviate–bots and people.

          I bookmark terms-of-service pages to read and re-read them. I manually type URLs of login pages. I occasionally browse the web whilst refusing to download media as I desire a purely textual experience.

          Images have a lot of power and are a vector of manipulation that we can’t guard against–it’s how we have evolved as a species. That vector is abused by advertisers specifically, but the images on a site do effect the context of the text as well. Strip away everything but the text and you’re dramatically hindering the author’s ability to persuade the reader emotionally.

          I’m not complaining and I do advise operators to do all that they can to prevent abuse of their services, but I’d just like to point out that the norm exists because the deviations exist too. Not serving those users is just collateral whilst blocking abusive actors.

          I can’t think of a better way to prevent abuse either. Encryption and strong user-authentication are my preferred tools at preventing abuse, but that sort of thing is not designed for a public website whose purpose is to provide a commons to users.

          • JustTesting@lemmy.hogru.ch
            link
            fedilink
            English
            arrow-up
            3
            ·
            8 hours ago

            The irony of all of this is that there’s like 5 people replying to me making assumptions when they have no idea what the circumstances are.

            I run a lemmy server, on pretty low power hardware, with closed registrations, that serves like 5 users, which is mostly friends. It has to be open to the internet, because lemmy. Other lemmy instances are whitlelisted, so federation works without problem. It does not have to serve anyone other than those 5 users. No one besides those 5 users can create an account, there’s tons of other lemmy instances better suited for random users, plus I don’t owe anyone other than my users anything. LLM scrapers have considerably harmed uptime/reachability of the instance in the past, going from like 99.9% to 96%, before introducing the very aggressive blocking. All the things I outlined in my original post helped significantly in reducing that traffic and actually making the instance work for those 5 users.

            You’re not one of my normal users, since you’re not one of my users at all. It is really ironic how everyone here jumps to conclusions that I’m like blocking half of the internet from accessing essential services or something. The original post was about how to completely block LLM scrapers. The referer rules get rid of about 30% of LLM scraper traffic in my case. Your mileage may vary, check what makes sense for your case. But all the comments here are like peak lemmy…

        • ExtraJudgement@lemmy.world
          link
          fedilink
          English
          arrow-up
          2
          ·
          15 hours ago

          Like no normal user will bookmark or paste a /login url.

          Guess I’m not “normal”. All the login pages for relevant services are bookmarks on my gethomepage.dev.

        • nacho@charla.gamingnight.uy
          link
          fedilink
          English
          arrow-up
          3
          ·
          21 hours ago

          I don’t know, especially for sites where I don’t care at all for the unauthenticated site, I have bookmarked login pages. Although it’s true that most times I bookmark the dashboard/home/whatever and get redirected to login.

          • JustTesting@lemmy.hogru.ch
            link
            fedilink
            English
            arrow-up
            2
            ·
            edit-2
            21 hours ago

            I’m not saying this is a catchall solution for everything. If you have a business with tens of thousands of users, sure. If you have 5 users that you know, it works very well. An the login page example is the latter case.

            It’s just a pattern i noticed, a lot of crawlers don’t set a referer, so that can serve as a signal, depending on circumstances.

            It also depends on your tolerance? Some false positives can be acceptable.

            Ever since those fucks started using residential proxies, you either allow them or you have to accept that you might block legitimate users. And in this specific case, those kinds of rules definitely make my life easier and if that means someone legit can’t access it, well, it’s best effort and I don’t have an obligation to make things work for everyone. it sucks and I wish the internet wasn’t like this nowadays. But the measures i described helped cut down thousands of requests/second to maybe 1-3. Most of those are likely still crawlers, but there’s only so much effort i am willing to spend to fight corporations with tens of thousands of times the manpower. If this is ever not enough, i’ll just shut things off tbh.

            P.s. i should also mention that i validated all of my rules against access logs covering a long-ish period of time and i did not see any false positives.

    • Vietconga@scribe.disroot.orgOP
      link
      fedilink
      English
      arrow-up
      3
      ·
      1 day ago

      After reading this comment I think I will lift muy web camp and move entirely to Gopher. Too much of a hassle for just a tiny blog.

      • JustTesting@lemmy.hogru.ch
        link
        fedilink
        English
        arrow-up
        7
        arrow-down
        1
        ·
        1 day ago

        Might I interest you in Gemini? The protocol, not googles llm. It’s like gopher in many ways, just more recent and comfortably active (in that you can read all there is in a day and be done with it, but there is stuff regularily).

        • dropdrip@lemmy.ml
          link
          fedilink
          English
          arrow-up
          1
          ·
          14 hours ago

          I have a hard time comprehending the rationale behind the use of Gemini when the same effect can be created by using a sane subset of HTML. I do not see the advantage of adopting Gemini over HTML. If I were to advocate for a move towards a different protocol it would be GNUnet–an attempt to rectify the deficiencies of the current protocol that benefits the users, not a regression to a subset of HTML-like attributes.

  • 9tr6gyp3@lemmy.world
    link
    fedilink
    English
    arrow-up
    80
    arrow-down
    2
    ·
    2 days ago

    Unplug the power plug and send your devices to ewaste. Even then, its not guaranteed to avoid LLMs.

  • 4TBHMeCCL@suppo.fi
    link
    fedilink
    English
    arrow-up
    27
    ·
    edit-2
    2 days ago

    I like looking at different lists to see what scrapers are listed (there’s ai.robots.txt, CrawlerCheck, “Ultimate Block List to Stop AI Bots” by Jeff Starr, the list from GEO Toolbox, Known Agents which was previously known as Dark Visitors). There’s also checking logs to see what other user agents (or such) appears.

    Instead of blocking, there’s some people who redirect the scrapers to honeypots or junk sites (do something unique and have a unique URL to have it harder for LLM to block, personally I like doing a url that is randomly generated).

    There’s also “secret botnets” that if you block a certain user-agent, they will reappear under a different IP and user-agent (neocities did a whole Bluesky thread on it, which is worth a read).

    You won’t be able to catch everything, but you can at least make it harder for them.

  • fruitycoder@sh.itjust.works
    link
    fedilink
    English
    arrow-up
    6
    ·
    2 days ago

    I mean for me, personally, wire guard vpn behind crowdsec (cluster to cluster vpns and then a user vpn). On my user vpn I access my apps through teleport then through the k8s ingress (traefik).

    I don’t see any issues expect people hitting the public side of my vpns.

    • SlicedPotato@feddit.dk
      link
      fedilink
      English
      arrow-up
      1
      ·
      4 hours ago

      I use GeoIP blocking as well, but with a default deny approach. Only my country, and one neighboring country that I frequently cross the border to, are allowed. I have a Wireguard as well which is allowed from select other countries too which I travel to less frequently. Normally I only use the WG tunnel to access administrative parts of my lab (SSH, etc), but when I’m in those countries I use it to access everything since the “public” parts of my lab are blocked.

    • Hal@piefed.nz
      link
      fedilink
      English
      arrow-up
      6
      ·
      1 day ago

      In my experience if you block areas like this, it slows down temporarily but then you see other SEA and South American countries pop up. You block them they just start proxying through thousands of residential IPs using their botnet of dodgy apps installed on people’s smart TVs.

      • Fabio Manganiello@manganiello.tech
        link
        fedilink
        arrow-up
        3
        ·
        1 day ago

        @Hal@piefed.nz I went through the same whack-a-mole - ended up aggressively doing iptables drop on whole class A/B subnets from Alibaba/Tencent data centers, just to see thousands of residential IPs with pseudo-legitimate user agents hammer me.

        I’m thankful that solutions like Anubis exist, even though it’s also high on CPU usage on a Forgejo box that gets hammered by a dozen of requests per sec.

        • Hal@piefed.nz
          link
          fedilink
          English
          arrow-up
          3
          ·
          22 hours ago

          Yeah, anubis has made a big difference. People see the proof of work screen, but a good half of traffic is just blocked without being challenged, just straight blocked, do to the risk rules.

          So much easier than manually blocking IPs or ASNs like I used to!

  • Nik282000@lemmy.ca
    link
    fedilink
    English
    arrow-up
    5
    ·
    2 days ago

    Anything that gets more that four 404 or 403 errors in 10min gets fail2banned. All my services are behind auth. Basic scanners get caught looking for services I don’t have, anything else gets caught trying to guess creds.

    • MonkderVierte@lemmy.zip
      link
      fedilink
      English
      arrow-up
      9
      arrow-down
      1
      ·
      edit-2
      9 hours ago

      Anything that gets more that four 404 or 403 errors in 10min gets fail2banned.

      If your site is in wordpress or another js-mess, i will fulfill that quota on first page load.

      • Nik282000@lemmy.ca
        link
        fedilink
        English
        arrow-up
        2
        ·
        15 hours ago

        Yeah, I donno how the fuck so many projects are so poorly built. It’s its own punishment.

  • confusedpuppy@lemmy.dbzer0.com
    link
    fedilink
    English
    arrow-up
    15
    ·
    2 days ago

    I just use a wildcard domain cert and a random higher port number while hiding my SSH port behind WireGuard. The only activity I see is from myself

    I just can’t be bothered to keep up the fight against AI/LLMs/Scrapers. I have my own quiet corner of the internet now while the robots can have rest of the easily accessible internet

    • Avid Amoeba@lemmy.ca
      link
      fedilink
      English
      arrow-up
      7
      ·
      2 days ago

      Can you elaborate on the setup? Is the reverse proxy blocking anything but preconfigured subdomains? Or some cert auth scheme?

      • confusedpuppy@lemmy.dbzer0.com
        link
        fedilink
        English
        arrow-up
        7
        ·
        2 days ago

        My ISP supplied modem/router doesn’t have a DMZ so I just port forward my reverse proxy port and WireGuard port.

        Then I use Caddy to handle a single wildcard domain cert. Caddy then redirects sub-domains to their respective localhost port number.

        My firewall redirects WireGuard connections to my SSH port.

        I don’t block anything. I only host static pages so I don’t use any authentication. If I hosted services then I would probably use some sort of authentication. Other than that, it’s really simple.

        In the past nearly 2 years I’ve been doing this I have had no one attempt to connect but myself. It’s nice having quiet and easy to parse logs.

    • Carl@anarchist.nexus
      link
      fedilink
      English
      arrow-up
      2
      ·
      edit-2
      1 day ago

      Similarly, I specifically don’t host anything on my base example.com and www.example.com subdomains. If anything hits either of those, they’re instantly blacklisted because I know they’re a bot. Because none of my services use those subdomains, so I know that only bots are attempting to access them.

      Also, if it attempts to access Wordpress, it gets instantly blocked. None of my services use Wordpress, and lots of malicious bots will probe it for vulnerable extensions. At one point, probes looking for default Wordpress settings were like 80% of my blocked bots.

  • monkeyman512@lemmy.world
    link
    fedilink
    English
    arrow-up
    7
    ·
    2 days ago

    I am confident putting everything behind VPN access and not directly exposing it to the Internet will work 100% of the time and continue working in the future. Everything else will be an arms race.

    I know that doesn’t actually help with the kind of solution you are looking for. But any time you can lock it behind VPN access will make it easier to secure.

  • rako@tarte.nuage-libre.fr
    link
    fedilink
    Français
    arrow-up
    4
    ·
    2 days ago

    I still find the iocaine approach the smartest. Let the primary crawler fetch urls (including and especially the tarpit ones) because they’re low traffic, and block most ips trying to access tarpit urls. Most, because you still want to grab ips that access tarpit urls to block them in the future. No need to block those ips eternally, they’ll only appear a few times, and worst of all they’re actual users’ ips so they might also appear for legitimate traffic.

    I do find it ethically better than blocking ips based on geographical regions. But blocking whole ASNs managed and used by tech companies is worth it. I saw a nice decrease banning Meta at IP level.