<?xml version="1.0" encoding="utf-8"?><?xml-stylesheet type="text/xsl" href="/atom.xsl"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
  <id>https://duggan.ie/tag/cloudflare/</id>
  <title type="text">@duggan — cloudflare</title>
  <updated>2025-12-15T00:34:13.000Z</updated>
  <author>
    <name>Ross Duggan</name>
    <email>ross@duggan.ie</email>
    <uri>https://duggan.ie/</uri>
  </author>
  <icon>https://duggan.ie/favicon.ico</icon>
  <link href="https://duggan.ie/tag/cloudflare/atom.xml" rel="first"/>
  <link href="https://duggan.ie/tag/cloudflare/atom.xml?page=1" rel="last"/>
  <link href="https://duggan.ie/tag/cloudflare/atom.xml" rel="self"/>
  <logo>https://duggan.ie/og-image.png</logo>
  <rights type="text">All rights reserved 2026, Ross Duggan</rights>
  <subtitle type="text">Posts tagged cloudflare</subtitle>
  <entry>
    <id>https://duggan.ie/posts/moving-cloudflare-out-of-the-critical-path</id>
    <title type="text">Moving Cloudflare out of the critical path</title>
    <updated>2025-12-15T00:34:13.000Z</updated>
    <author>
      <name>Ross Duggan</name>
      <email>ross@duggan.ie</email>
      <uri>https://duggan.ie/</uri>
    </author>
    <content type="html">&lt;p&gt;&lt;/p&gt;&lt;figure class="image-wrapper"&gt;&lt;img src="/files/59ec86af09b7aaef.png" alt="BLOG-3079_2.png" width="inherit" height="inherit"&gt;&lt;/figure&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;By way of disclaimer: I really like Cloudflare, I've been a customer and (minor) shareholder for years, and I will continue to use them.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;My general principle around infrastructure outages is to stick with the providers that make mistakes. The good ones learn from those mistakes, improve their processes, and improve reliability. Plus I can't even recall the last time a Cloudflare outage occurred before that, let alone took down a good chunk of the Internet. If anything it's a testament to both their scale and remarkable resilience.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt; However, the extended &lt;/span&gt;&lt;a href="https://blog.cloudflare.com/18-november-2025-outage/" rel="noreferrer"&gt;&lt;span style="white-space: pre-wrap;"&gt;outage on November 18th&lt;/span&gt;&lt;/a&gt;&lt;span style="white-space: pre-wrap;"&gt; was long enough that I started wondering whether I &lt;/span&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;really&lt;/em&gt;&lt;/i&gt;&lt;span style="white-space: pre-wrap;"&gt; needed Cloudflare to be in the critical request path for my blog. Mostly in the name of being thoughtful about technical decisions.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;During the outage, the only way to potentially route around Cloudflare was using their API to disable request proxying – and this was contingent on your origin server already being set up to handle SSL traffic and being able to handle the increase in load.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;a href="https://news.ycombinator.com/item?id=45966041" rel="noreferrer"&gt;&lt;span style="white-space: pre-wrap;"&gt;Alexander Belanger posted a handy comment on Hacker News detailing the process&lt;/span&gt;&lt;/a&gt;&lt;span style="white-space: pre-wrap;"&gt;:&lt;/span&gt;&lt;/p&gt;&lt;details class="bg-zinc-50 dark:bg-zinc-800 border border-zinc-200 dark:border-zinc-700 rounded-lg mb-2" open="true"&gt;&lt;summary class="cursor-pointer py-1 px-6 relative font-bold list-none outline-none text-zinc-900 dark:text-zinc-100 [&amp;::-webkit-details-marker]:hidden [&amp;::marker]:hidden before:content-[''] before:block before:absolute before:left-2 before:top-1/2 before:-translate-y-1/2 before:w-0 before:h-0 before:border-[6px] before:border-transparent before:border-l-black dark:before:border-l-white before:rotate-0 before:transition-transform [details[open]_&amp;]:before:rotate-90 [div[data-open]_&amp;]:before:rotate-90 hover:bg-zinc-100 dark:hover:bg-zinc-700/50"&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;abelanger | on: Cloudflare Global Network experiencing issues&lt;/span&gt;&lt;/p&gt;&lt;/summary&gt;&lt;div class="px-5 pb-1 pt-0 text-zinc-900 dark:text-zinc-100" data-lexical-collapsible-content="true"&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;If anyone needs commands for turning off the CF proxy for their domains and happens to have a Cloudflare API token.&lt;/span&gt;&lt;/p&gt;&lt;p style="text-align: start;"&gt;&lt;span style="white-space: pre-wrap;"&gt;First you can grab the zone ID via:&lt;/span&gt;&lt;/p&gt;&lt;pre class="editor-code line-numbers" spellcheck="false" data-highlight-language="javascript" data-gutter="1
2"&gt;&lt;span style="white-space: pre-wrap;"&gt;    curl &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;-&lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;X&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;GET&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenString" style="white-space: pre-wrap;"&gt;"https://api.cloudflare.com/client/v4/zones"&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;-&lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;H&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenString" style="white-space: pre-wrap;"&gt;"Authorization: Bearer $API_TOKEN"&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;-&lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;H&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenString" style="white-space: pre-wrap;"&gt;"Content-Type: application/json"&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;|&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; jq &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;-&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt;r &lt;/span&gt;&lt;span class="editor-tokenString" style="white-space: pre-wrap;"&gt;'.result[] | "\(.id) \(.name)"'&lt;/span&gt;&lt;br&gt;&lt;/pre&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;And a list of DNS records using:&lt;/span&gt;&lt;/p&gt;&lt;pre class="editor-code line-numbers" spellcheck="false" data-highlight-language="javascript" data-gutter="1
2"&gt;&lt;span style="white-space: pre-wrap;"&gt;    curl &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;-&lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;X&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;GET&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenString" style="white-space: pre-wrap;"&gt;"https://api.cloudflare.com/client/v4/zones/$ZONE_ID/dns_records"&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;-&lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;H&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenString" style="white-space: pre-wrap;"&gt;"Authorization: Bearer $API_TOKEN"&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;-&lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;H&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenString" style="white-space: pre-wrap;"&gt;"Content-Type: application/json"&lt;/span&gt;&lt;br&gt;&lt;/pre&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;Each DNS record will have an ID associated. Finally patch the relevant records:&lt;/span&gt;&lt;/p&gt;&lt;pre class="editor-code line-numbers" spellcheck="false" data-highlight-language="javascript" data-gutter="1
2"&gt;&lt;span style="white-space: pre-wrap;"&gt;    curl &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;-&lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;X&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;PATCH&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenString" style="white-space: pre-wrap;"&gt;"https://api.cloudflare.com/client/v4/zones/$ZONE_ID/dns_records/$RECORD_ID"&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;-&lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;H&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenString" style="white-space: pre-wrap;"&gt;"Authorization: Bearer $API_TOKEN"&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;-&lt;/span&gt;&lt;span class="editor-tokenConstant" style="white-space: pre-wrap;"&gt;H&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenString" style="white-space: pre-wrap;"&gt;"Content-Type: application/json"&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt; &lt;/span&gt;&lt;span class="editor-tokenOperator" style="white-space: pre-wrap;"&gt;--&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt;data &lt;/span&gt;&lt;span class="editor-tokenString" style="white-space: pre-wrap;"&gt;'{"proxied":false}'&lt;/span&gt;&lt;br&gt;&lt;/pre&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;Copying from a sibling comment - some warnings:&lt;/span&gt;&lt;/p&gt;&lt;p style="text-align: start;"&gt;&lt;span style="white-space: pre-wrap;"&gt;- SSL/TLS: You will likely lose your Cloudflare-provided SSL certificate. Your site will only work if your origin server has its own valid certificate.&lt;/span&gt;&lt;/p&gt;&lt;p style="text-align: start;"&gt;&lt;span style="white-space: pre-wrap;"&gt;- Security &amp; Performance: You will lose the performance benefits (caching, minification, global edge network) and security protections (DDoS mitigation, WAF) that Cloudflare provides.&lt;/span&gt;&lt;/p&gt;&lt;p style="text-align: start;"&gt;&lt;span style="white-space: pre-wrap;"&gt;- This will also reveal your backend internal IP addresses. Anyone can find permanent logs of public IP addresses used by even obscure domain names, so potential adversaries don't necessarily have to be paying attention at the exact right time to find it.&lt;/span&gt;&lt;/p&gt;&lt;/div&gt;&lt;/details&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;This ended up being what I did, with some minor tweaks that I included in the comment thread around using global API keys and checking &lt;/span&gt;&lt;span&gt;&lt;span style="white-space: pre-wrap;"&gt;origin firewall rules&lt;/span&gt;&lt;sup&gt;[1]&lt;/sup&gt;&lt;/span&gt;&lt;span style="white-space: pre-wrap;"&gt;.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;My blog does not receive enough ordinary traffic to warrant a globally distributed CDN, and since I use LetsEncrypt on the origin server, I'm not relying on Cloudflare for SSL termination.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;The two main things I'm using Cloudflare for are caching and security. I'm interested to see how far I can get with my own efforts on caching – I have spent a lot of time fiddling with caching over the years.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;Security, DoS protection, etc., are also something I'm familiar with, but not to the point of reproducing Cloudflare's capabilities. Still, I am willing to see if &lt;/span&gt;&lt;a href="https://github.com/fail2ban/fail2ban" rel="noreferrer"&gt;&lt;span style="white-space: pre-wrap;"&gt;fail2ban&lt;/span&gt;&lt;/a&gt;&lt;span style="white-space: pre-wrap;"&gt; with some LLM-curated filters and an aggressive policy against scanners is going to be enough to keep things ticking over.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;There are some anti-spam and quality-of-life stuff Cloudflare does too, like &lt;/span&gt;&lt;a href="https://developers.cloudflare.com/waf/tools/scrape-shield/email-address-obfuscation/" rel="noreferrer"&gt;&lt;span style="white-space: pre-wrap;"&gt;email address obfuscation&lt;/span&gt;&lt;/a&gt;&lt;span style="white-space: pre-wrap;"&gt;, and JS/CSS/image optimisation. I like email obfuscation in theory, but I drop my public email address everywhere, so I'm not sure it has any practical benefit!&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;The great thing is that my blog is architecturally very simple, with all the content and images in an SQLite database that is live replicated with litestream, and occasionally manually dumped to my own laptop. It's all running on a €5/month VPS with Hetzner, and if it gets taken down reproducing it isn't a big deal.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;In fact I'm still using Cloudflare for DNS, so I can just pop over to the dashboard and re-enable the proxy easily enough. If the DNS fails at some point I might revisit :)&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;For my blog, I like the idea of having no intermediate proxy between myself or the reader and the server. It's a bit more old school, but also simpler, and aligns with my desire to occasionally reevaluate my default choices.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;Developer folk wisdom tells us to &lt;/span&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;use the right tool for the job&lt;/em&gt;&lt;/i&gt;&lt;span style="white-space: pre-wrap;"&gt;, but also to &lt;/span&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;use the tools you know&lt;/em&gt;&lt;/i&gt;&lt;span style="white-space: pre-wrap;"&gt;, two good principles that can be in tension with each other. It has always felt crucial for me to make sure I am not using familiar tools on the wrong problems though. That is laziness, and not &lt;/span&gt;&lt;a href="https://wiki.c2.com/?LazinessImpatienceHubris" rel="noreferrer"&gt;&lt;span style="white-space: pre-wrap;"&gt;the good kind&lt;/span&gt;&lt;/a&gt;&lt;span style="white-space: pre-wrap;"&gt;.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;That said, this is not a choice I think I would make in a professional capacity, especially if Cloudflare was handling a good chunk of my CDN traffic. As a passive and inexpensive service, it would need to do a lot worse to turn me off using it. Not a bad idea to have that &lt;/span&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;disable proxy&lt;/em&gt;&lt;/i&gt;&lt;span style="white-space: pre-wrap;"&gt; logic written up in a script somewhere though.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;If my blog ends up being defaced, or dropping offline from attacks, I will count it as an interesting, and perhaps very cheap, lesson.&lt;/span&gt;&lt;/p&gt;&lt;hr&gt;&lt;p dir="ltr"&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;There is currently no comments system. If you'd like to share an opinion either with me or about this post, please feel free to do so with me either via email (&lt;/em&gt;&lt;/i&gt;&lt;a href="mailto:ross@duggan.ie" rel="noreferrer" dir="ltr"&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;ross@duggan.ie&lt;/em&gt;&lt;/i&gt;&lt;/a&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;) on Mastodon (&lt;/em&gt;&lt;/i&gt;&lt;a href="http://mastodon.ie/@duggan" rel="noreferrer" dir="ltr"&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;@duggan@mastodon.ie&lt;/em&gt;&lt;/i&gt;&lt;/a&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;) or even on &lt;/em&gt;&lt;/i&gt;&lt;a href="https://news.ycombinator.com/item?id=46296051" rel="noreferrer" dir="ltr"&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;Hacker News&lt;/em&gt;&lt;/i&gt;&lt;/a&gt;&lt;a href="https://news.ycombinator.com/item?id=46296051" rel="noreferrer"&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;.&lt;/em&gt;&lt;/i&gt;&lt;/a&gt;&lt;/p&gt;&lt;p dir="ltr"&gt;&lt;i&gt;&lt;em class="italic" style="white-space: pre-wrap;"&gt;Edit, 2025-12-17: updated to include a link to the Hacker News discussion.&lt;/em&gt;&lt;/i&gt;&lt;/p&gt;&lt;div class="footnotes"&gt;&lt;hr&gt;&lt;p&gt;&lt;strong&gt;Notes:&lt;/strong&gt;&lt;/p&gt;&lt;ol&gt;&lt;li&gt;&lt;span style="white-space: pre-wrap;"&gt;I had been blocking all non-Cloudflare traffic to the server to stop the drive-by random scans of all IP addresses that otherwise happen constantly.&lt;/span&gt;&lt;/li&gt;&lt;/ol&gt;&lt;/div&gt;</content>
    <link href="https://duggan.ie/posts/moving-cloudflare-out-of-the-critical-path" rel="alternate"/>
    <published>2025-12-16T17:14:45.183Z</published>
    <summary type="html">&lt;p&gt;&lt;span style="white-space: pre-wrap;"&gt;I'm a big fan of Cloudflare, but the extended outage on November 18th was long enough that I started wondering whether I really needed it to be in the critical request path for my blog.&lt;/span&gt;&lt;/p&gt;</summary>
  </entry>
</feed>