Sefism is free for learners. We are here to help you grow, one step at a time.Join for free
Sefism.
Web

Fair Scraper Gate for Small Websites with Adaptive Proof of Work and Signed AI Agent Verification

Build a self-hosted reverse proxy that protects small websites from aggressive AI scrapers while staying fair to real people on cheap phones and to well-behaved agents that identify themselves. It combines adaptive proof-of-work challenges with verification of cryptographically signed bot requests, and measures the cost it puts on low-end devices. University sites, open source forges and small archives are the people who need it most.

Difficulty

Advanced

Needs a team, real planning, and a supervisor who knows the area.
Effort

2 semesters · 2 to 3 students

Deliverables

8 to ship

3 optional extras

Suggested stack

Go or RustReverse proxy (net/http or hyper)Web Crypto API and WebAssemblyHTTP Message Signatures (RFC 9421)RedisPrometheus and Grafana
A suggestion, not a requirement. Swap anything for what you already know.

What you should ship

  • A reverse proxy that sits in front of any site and passes normal traffic with minimal delay
  • A proof-of-work challenge page with a no-JavaScript fallback and an accessible design
  • Adaptive difficulty based on request rate, path cost and client history, not a single global setting
  • Verification of signed bot and agent requests using HTTP Message Signatures and published key directories
  • Policy rules: allow, challenge, rate-limit or block per path, per verified agent and per network
  • Metrics dashboards for challenge rates, pass rates, solve times and origin load saved
  • A fairness study measuring solve time and battery cost on low-end and mid-range Android phones
  • A load test that replays scraper-like traffic and shows the origin staying healthy

If you have time left

  • A WordPress and Gitea or Forgejo deployment guide with tuned defaults
  • Signed cookies shared across a group of sites run by the same university
  • A public report of scraper behaviour seen across volunteer deployments

The problem: scrapers that take a small site down

Since 2024, many small websites have been hit by crawlers collecting training data for AI models. They ignore robots.txt, rotate through thousands of IP addresses and request every page, every commit and every search result. Open source code forges, university course pages, digital archives and community wikis have reported slowdowns and outages caused by this traffic. The people running them are often volunteers or a single IT officer.

Blocking everything automated is not the answer either. Search engines, accessibility tools, research crawlers and the new generation of AI agents acting for real users all have legitimate reasons to visit. And the people most hurt by heavy browser challenges are users on cheap phones and slow connections, which describes much of the audience in Pakistan and South Asia.

What already exists and the gap

  • Anubis, an open source tool released in January 2025 and now maintained by Techaro, places a SHA-256 proof-of-work challenge in front of a site. It has been adopted by projects such as GNOME's GitLab, FFmpeg and the Linux kernel mailing list archives.
  • Cloudflare offers bot management, Turnstile challenges and support for Web Bot Auth, an IETF draft built on HTTP Message Signatures (RFC 9421) that lets bots and agents prove who they are with a signature and a published key.
  • Rate limiting in NGINX or a web application firewall helps against single sources, but not against traffic spread over thousands of addresses.

The gap your project explores is a self-hosted gate that combines both ideas (make anonymous bulk crawling expensive, let identified agents through under clear rules) and treats fairness to low-end devices as a measured requirement, not an afterthought.

Inspiration

Two sources shape this project. Adam Back's Hashcash (2002) proposed proof of work as a cost on senders of bulk email: cheap for one message, expensive for millions. Anubis applies the same economics to web requests. Web Bot Auth, documented by Cloudflare and proposed at the IETF, shows how a well-behaved agent can sign its requests so a site can verify it without guessing from the user agent string. Your project brings the two together and measures the trade-offs.

What you build

  • Site operators run the gate as a container in front of their site, choose a preset, and watch dashboards.
  • Visitors usually see nothing; under suspicious load, they see a short, accessible challenge that solves in the background.
  • Agent operators sign their requests, register their key directory, and get predictable access under published rate limits.

The technically interesting part

  • Adaptive difficulty. A fixed challenge either annoys everyone or stops nobody. Raise difficulty for expensive paths (search, archives, diffs) and for clients that request many pages quickly, and lower it for returning visitors with a valid token.
  • Fair to cheap phones. Measure solve time on real low-end phones. Explore memory-hard puzzles, a cap on worst-case solve time, and a no-JavaScript path such as a simple wait page.
  • Signature verification. Fetch and cache key directories, check signature windows and replay protection, and handle key rotation.
  • Low overhead. The proxy must add very little latency for normal traffic. Benchmark it.
  • Honest metrics. Separate "challenged", "solved", "verified agent" and "blocked", and estimate how much origin load was saved.

How to evaluate it

  • Origin protection: origin CPU and response times during a replayed scraper load, with and without the gate.
  • Human cost: median and worst-case solve times and battery use on three phone classes.
  • Agent path: correctness of signature verification against valid, expired, replayed and forged requests.
  • Overhead: added latency at the 50th and 99th percentile for normal traffic.

Suggested plan

  • Weeks 1 to 4: read Hashcash, the Anubis documentation and the Web Bot Auth drafts; build a basic proxy.
  • Weeks 5 to 10: challenge page, token issuing and adaptive difficulty.
  • Weeks 11 to 15: signature verification, policy rules and metrics.
  • Weeks 16 to 20: load tests, low-end phone study and tuning.
  • Weeks 21 to 26: deployment guide, write-up and demo.

Path to a product

Universities, public archives, NGOs and small hosting companies all need protection they can run themselves. A free open source gate with paid support, or a managed version for hosting providers, is a realistic path. The fairness study is useful to the wider community, and the project is a strong portfolio piece for backend, security and infrastructure roles.

Scope warning

Do not try to build a full bot management platform or fingerprint users; that raises privacy problems and is a different project. Keep the policy language small. Test only against your own sites and replayed traffic, never against third-party services. Fairness on low-end devices is the core of this project, so measure it from the start.

Learn what you need on Sefism

Get help with this idea

The risk is a gate that punishes real users more than scrapers, or a study with no real measurements. Tauseef can help you set the fairness targets, design the load tests and scope the policy rules. If you are new here, create a free account first.

Ideas and guidance, not finished projects

These are project ideas and scoping guidance, published free for students to use as a starting point. I do not build, write, or sell final-year projects, and I do not complete coursework for anyone. Take an idea, make it yours, and build it.

Not sure this one fits you?

I help students pick an idea that matches their skills and their deadline, then scope it down until it is finishable. Guidance only, never done for you.

Discuss this idea
Work with me

Stuck on something specific?

Writing only gets you so far. If you want an answer to your situation rather than the general case, book a session and we will work through it together. Sessions are free for approved Sefism members, and a few slots open each week.