SShortSingh.
Back to feed

How a Peruvian election site split Cloudflare's Free-plan WAF rules across six slots

0
·5 views

The author runs Elección Clara, a Peruvian site about candidates, parties and government, built with SvelteKit on a Cloudflare Worker with a Go API behind it. Cloudflare's Free plan offers only five custom rules and one rate-limiting rule, so the author had to decide which problems each slot should address. Requests blocked at the edge never reach the Worker, so the author had to use Cloudflare's Security Events to see what was filtered. The policy allows verified search engines, link previewers and AI assistants answering user queries, while blocking training crawlers, SEO tools, generic scrapers and datacenter traffic that is not a verified bot. The article also describes three things that went wrong and a closing checklist, and it omits specific rule expressions, thresholds and path lists.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingHacker News ·

Crystal GTK Bindings Maintainer Announces Archiving of the Project

A maintainer of the Crystal programming language's GTK bindings has announced on the Crystal forum that the project is being archived. The post was shared on Hacker News, where it drew modest attention with seven points and one comment. The available material does not describe the specific reasons behind the decision. Developers who depend on the bindings may need to look for alternatives or consider maintaining a fork.

0
ProgrammingHacker News ·

Classics of Science Fiction Publishes Guide for Readers Who Dislike the Genre

A post on the Classics of Science Fiction blog offers recommendations aimed at people who typically don't enjoy science fiction. The article was published on December 5, 2026, according to its URL. It was shared on Hacker News, where it gathered 6 points and one comment. The source material provided is limited to the link and metadata, so the specific titles and arguments the post makes cannot be confirmed here.

0
ProgrammingDEV Community ·

Python Circuit Breaker Guards Against Slow External APIs Triggering Outages

A sudden load spike slowed a user profile API from hundreds of milliseconds to several seconds, and the system's connection pools were exhausted while waiting on those calls. The resulting backlog blocked new requests and turned a partial external degradation into a full infrastructure outage. The author concludes that slow APIs can be more harmful than failed ones, since waiting on timeouts compounds the damage. To address this, they outline a lightweight circuit breaker built with only the Python standard library plus Pydantic and orjson, requiring fail-fast opening, safe fallbacks, and strict payload validation. The article includes a state diagram of the CLOSED, OPEN, and HALF-OPEN transitions and a CLI validation script.

0
ProgrammingDEV Community ·

Why Internal X.509 Certificates Should Not Be Pasted Into Online Decoders

Engineers often paste internal TLS certificates into online decoders when handshakes fail, which can leak private hostnames, IP ranges, and internal CA structures. Certificate bundles may also accidentally include private keys, adding risk. The article argues that certificates can be parsed locally in the browser, with all processing staying in memory on the user's machine. It also explains that under RFC 6125, a wildcard certificate covers only a single left-most label, so nested subdomains and the apex domain may not match. The author describes a tool that checks hostname coverage against certificate SANs locally before deployment.