

{"id":13717,"date":"2023-02-27T15:34:25","date_gmt":"2023-02-27T20:34:25","guid":{"rendered":"https:\/\/rud.is\/b\/?p=13717"},"modified":"2023-02-27T15:34:25","modified_gmt":"2023-02-27T20:34:25","slug":"bizarre-dns-hacks-for-fun-and-um-fun","status":"publish","type":"post","link":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/","title":{"rendered":"&#8220;Bizarre&#8221; DNS Hacks For Fun And,  Um\u2026, Fun"},"content":{"rendered":"<p>I&#8217;ve been (slowly) making my way through FOSDEM `23 presentations and caught up to <a href=\"https:\/\/fosdem.org\/2023\/schedule\/speaker\/peter_lowe\/\">Peter Lowe<\/a>&#8216;s &#8220;<a href=\"https:\/\/fosdem.org\/2023\/schedule\/event\/dns_bizarre_and_unusual_uses_of_dns\/\">Bizarre and Unusual Uses of DNS \u2022 Rule 53: If you can think of it, someone&#8217;s done it in the DNS<\/a>&#8221; talk. DNS oddities are items I collect whenever I see them, and while I knew about a good number of the ones in Peter&#8217;s presentation, the ones where DNS is used to retrieve your external IP address were oddly missing from my collection.<\/p>\n<p>His presentation mentioned both a Google DNS hack and OpenDNS DNS hack, and I learned of a similar DNS hack from Akamai from <a href=\"https:\/\/elk.zone\/sackheads.social\/@john\/109937030925512809\">John Payne<\/a>. I keep saying &#8220;hack&#8221; because these folks are most certainly abusing the original intentions and design of DNS. &#8220;Hack&#8221; is not being used pejoratively, as this is a pretty cool and efficient way of discovering your external IP address vs setting up a full-blown HTTP TLS session, making a <code>GET<\/code> request and retrieving the payload.<\/p>\n<p>I&#8217;ve been Down and Out on COVID Street for the past few weeks (#4 brought it home from high school, making multiple years of being overly cautious and careful outside the house quite moot), and had a bit of a level drain relapse over the weekend, so I decided to get my mind directed away from malicious spike proteins and build a client for the existing services and then a server anyone could run to host the same type of service.<\/p>\n<p>I&#8217;ve been nerding out on Rust for the past few years, but chose Go (also calling it &#8220;Golang&#8221; in this parenthetical for the sake of SEO) since I really wanted a small binary, and DNS ops are part of Go&#8217;s &#8220;batteries included&#8221; libraries (and, I&#8217;ve worked with them before).<\/p>\n<h3>dig-ging The Hacks<\/h3>\n<p><a href=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?ssl=1\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" data-attachment-id=\"13728\" data-permalink=\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/can_you_dig_it-3433\/\" data-orig-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?fit=500%2C500&amp;ssl=1\" data-orig-size=\"500,500\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"Can You Dig It\" data-image-description=\"&lt;p&gt;Shaft Silhouette with Can You Dig It below&lt;\/p&gt;\n\" data-image-caption=\"\" data-medium-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?fit=300%2C300&amp;ssl=1\" data-large-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?fit=500%2C500&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?resize=500%2C500&#038;ssl=1\" alt=\"Shaft Silhouette with Can You Dig It below\" width=\"500\" height=\"500\" class=\"aligncenter size-full wp-image-13728\" srcset=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?w=500&amp;ssl=1 500w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?resize=300%2C300&amp;ssl=1 300w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?resize=150%2C150&amp;ssl=1 150w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?resize=400%2C400&amp;ssl=1 400w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?resize=200%2C200&amp;ssl=1 200w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?resize=57%2C57&amp;ssl=1 57w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?resize=72%2C72&amp;ssl=1 72w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?resize=114%2C114&amp;ssl=1 114w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?resize=144%2C144&amp;ssl=1 144w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/Can_You_Dig_It-3433.jpeg?resize=96%2C96&amp;ssl=1 96w\" sizes=\"auto, (max-width: 500px) 100vw, 500px\" \/><\/a><\/p>\n<p>You don&#8217;t <em>need<\/em> a special client for these hacks. <code>dig<\/code> can do all the hard work for you, and it is (for the most part) on every modern system (or easily installed).<\/p>\n<p>Here are three shell executable statements that will return your external IP address into a shell variable (just remove the <code>VAR=<\/code> and outer <code>$()<\/code> to see the result vs store it):<\/p>\n<pre><code class=\"language-bash\">MY_OPENDNS_IP=\"$(dig myip.opendns.com @resolver1.opendns.com +short)\"\n\nMY_GOOGLE_IP=\"$(dig o-o.myaddr.1.google.com @ns1.google.com TXT +short | tr -d '\"')\"\n\nMY_AKAMAI_IP=\"$(dig +short TXT whoami.ds.akahelp.net @$(dig +short +answer NS akamai.com | head -1) | grep ns | sed -e 's\/[^0-9\\.\\:]\/\/g')\"\n<\/code><\/pre>\n<p>The Akamai one is a bit longer since I didn&#8217;t want to lock it in to a pre-specified Akamai resolver (you never know when orgs are going to change things). So, it looks up the nameserver first, then does the IP check.<\/p>\n<p>Remove the pipes to see the &#8220;raw&#8221; output.<\/p>\n<h3>[Client] Hacks In Go<\/h3>\n<p><a href=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?ssl=1\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" data-attachment-id=\"13730\" data-permalink=\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/man-in-the-hood\/\" data-orig-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?fit=600%2C399&amp;ssl=1\" data-orig-size=\"600,399\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;8&quot;,&quot;credit&quot;:&quot;Getty Images\/iStockphoto&quot;,&quot;camera&quot;:&quot;Canon EOS 7D&quot;,&quot;caption&quot;:&quot;Silhouette of hooded man or hooligan over dark concrete background with copy space&quot;,&quot;created_timestamp&quot;:&quot;1343952000&quot;,&quot;copyright&quot;:&quot;Nastco&quot;,&quot;focal_length&quot;:&quot;48&quot;,&quot;iso&quot;:&quot;100&quot;,&quot;shutter_speed&quot;:&quot;0.00625&quot;,&quot;title&quot;:&quot;Man in the hood&quot;,&quot;orientation&quot;:&quot;1&quot;}\" data-image-title=\"Gopher in the hood\" data-image-description=\"\" data-image-caption=\"&lt;p&gt;Silhouette of hooded man gopher or hooligan over dark concrete background with copy space&lt;\/p&gt;\n\" data-medium-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?fit=300%2C200&amp;ssl=1\" data-large-file=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?fit=510%2C339&amp;ssl=1\" src=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?resize=510%2C339&#038;ssl=1\" alt=\"Go&#039;s mascot in a hacker hoodie\" width=\"510\" height=\"339\" class=\"aligncenter size-full wp-image-13730\" srcset=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?w=600&amp;ssl=1 600w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?resize=300%2C200&amp;ssl=1 300w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?resize=530%2C352&amp;ssl=1 530w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?resize=150%2C100&amp;ssl=1 150w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?resize=500%2C333&amp;ssl=1 500w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?resize=400%2C266&amp;ssl=1 400w, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2020-03-29-golang-hacker.jpg?resize=200%2C133&amp;ssl=1 200w\" sizes=\"auto, (max-width: 510px) 100vw, 510px\" \/><\/a><\/p>\n<p>I&#8217;ll eventually set up a GitHub Action to build out binaries for various platforms (and setup a Homebrew tap for it) but you can get started using the nascent Go CLI via:<\/p>\n<pre><code class=\"language-bash\">go install -ldflags \"-s -w\" github.com\/hrbrmstr\/extip@latest\n<\/code><\/pre>\n<p>the extra flags are there to make the binary size smaller than it otherwise would be (Go and Rust both make larger binaries than I care for, but they do that for good reasons).<\/p>\n<p>At present, there are no command line options, so when you run <code>extip<\/code>, the executable makes the DNS calls to all three services and will return just your IP address if they all agree (if you&#8217;re being service intercepted in a really nasty way, that might not be the case). If any fail, the discrepancies are shown.<\/p>\n<h3>Serving Up Your Own Hack<\/h3>\n<p>Another reason to use Go is that building a DNS <em>server<\/em> in it is super straightforward, thanks to <a href=\"https:\/\/mastodon.cloud\/@miek\">Miek Gieben<\/a>&#8216;s battle tested <a href=\"https:\/\/github.com\/miekg\/dns\">DNS library<\/a>.<\/p>\n<p>Now, thanks to <a href=\"https:\/\/github.com\/hrbrmstr\/extip-svr\">this tiny, hacky DNS server I whipped up<\/a>, you can:<\/p>\n<pre><code class=\"language-bash\">go install -ldflags \"-s -w\" github.com\/hrbrmstr\/extip-svr@latest\n<\/code><\/pre>\n<p>and run it anywhere you&#8217;d like to have the same type of service.<\/p>\n<p>It supports <code>A<\/code>, <code>AAAA<\/code> and <code>TXT<\/code> queries, though I&#8217;d use the <code>TXT<\/code> one if I were you, since you don&#8217;t need to know what type of network you&#8217;re on or interface the request is coming from. I&#8217;ve got it running on one of my random internet nodes, so you can try it out before running it:<\/p>\n<pre><code class=\"language-bash\">dig myip.is TXT @ip.rudis.net\n<\/code><\/pre>\n<p>(any FQDN ending in <code>.is<\/code> can be used)<\/p>\n<h3>FIN<\/h3>\n<p>Peter&#8217;s talk was super fun and informative, so you should 100% watch it. It was great being able to have something to focus on whilst getting better, and also cool to stretch some Golang muscles.<\/p>\n<p>If you have any opines on the CLI argument parser I should use, drop a comment or issue on the repos. I&#8217;ll be tweaking both the client and server quite a bit over the coming weeks.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;ve been (slowly) making my way through FOSDEM `23 presentations and caught up to Peter Lowe&#8216;s &#8220;Bizarre and Unusual Uses of DNS \u2022 Rule 53: If you can think of it, someone&#8217;s done it in the DNS&#8221; talk. DNS oddities are items I collect whenever I see them, and while I knew about a good [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":13724,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"activitypub_content_warning":"","activitypub_content_visibility":"","activitypub_max_image_attachments":3,"activitypub_interaction_policy_quote":"anyone","activitypub_status":"","footnotes":""},"categories":[74,840,841,704],"tags":[],"class_list":["post-13717","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-dns","category-go","category-golang","category-hacks"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.2 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>&quot;Bizarre&quot; DNS Hacks For Fun And, Um\u2026, Fun - rud.is<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"&quot;Bizarre&quot; DNS Hacks For Fun And, Um\u2026, Fun - rud.is\" \/>\n<meta property=\"og:description\" content=\"I&#8217;ve been (slowly) making my way through FOSDEM `23 presentations and caught up to Peter Lowe&#8216;s &#8220;Bizarre and Unusual Uses of DNS \u2022 Rule 53: If you can think of it, someone&#8217;s done it in the DNS&#8221; talk. DNS oddities are items I collect whenever I see them, and while I knew about a good [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/\" \/>\n<meta property=\"og:site_name\" content=\"rud.is\" \/>\n<meta property=\"article:published_time\" content=\"2023-02-27T20:34:25+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2069959_1.jpg?fit=630%2C630&ssl=1\" \/>\n\t<meta property=\"og:image:width\" content=\"630\" \/>\n\t<meta property=\"og:image:height\" content=\"630\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"hrbrmstr\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"hrbrmstr\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/\"},\"author\":{\"name\":\"hrbrmstr\",\"@id\":\"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886\"},\"headline\":\"&#8220;Bizarre&#8221; DNS Hacks For Fun And, Um\u2026, Fun\",\"datePublished\":\"2023-02-27T20:34:25+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/\"},\"wordCount\":737,\"commentCount\":1,\"publisher\":{\"@id\":\"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886\"},\"image\":{\"@id\":\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2069959_1.jpg?fit=630%2C630&ssl=1\",\"articleSection\":[\"DNS\",\"Go\",\"Golang\",\"hacks\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/\",\"url\":\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/\",\"name\":\"\\\"Bizarre\\\" DNS Hacks For Fun And, Um\u2026, Fun - rud.is\",\"isPartOf\":{\"@id\":\"https:\/\/rud.is\/b\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2069959_1.jpg?fit=630%2C630&ssl=1\",\"datePublished\":\"2023-02-27T20:34:25+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#primaryimage\",\"url\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2069959_1.jpg?fit=630%2C630&ssl=1\",\"contentUrl\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2069959_1.jpg?fit=630%2C630&ssl=1\",\"width\":630,\"height\":630,\"caption\":\"silhouette of a couple with \\\"It\u2026It was DNS\\\" over them\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/rud.is\/b\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"&#8220;Bizarre&#8221; DNS Hacks For Fun And, Um\u2026, Fun\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/rud.is\/b\/#website\",\"url\":\"https:\/\/rud.is\/b\/\",\"name\":\"rud.is\",\"description\":\"&quot;In God we trust. All others must bring data&quot;\",\"publisher\":{\"@id\":\"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/rud.is\/b\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886\",\"name\":\"hrbrmstr\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1\",\"url\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1\",\"contentUrl\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1\",\"width\":460,\"height\":460,\"caption\":\"hrbrmstr\"},\"logo\":{\"@id\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1\"},\"description\":\"Don't look at me\u2026I do what he does \u2014 just slower. #rstats avuncular \u2022 ?Resistance Fighter \u2022 Cook \u2022 Christian \u2022 [Master] Chef des Donn\u00e9es de S\u00e9curit\u00e9 @ @rapid7\",\"sameAs\":[\"http:\/\/rud.is\"],\"url\":\"https:\/\/rud.is\/b\/author\/hrbrmstr\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\"Bizarre\" DNS Hacks For Fun And, Um\u2026, Fun - rud.is","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/","og_locale":"en_US","og_type":"article","og_title":"\"Bizarre\" DNS Hacks For Fun And, Um\u2026, Fun - rud.is","og_description":"I&#8217;ve been (slowly) making my way through FOSDEM `23 presentations and caught up to Peter Lowe&#8216;s &#8220;Bizarre and Unusual Uses of DNS \u2022 Rule 53: If you can think of it, someone&#8217;s done it in the DNS&#8221; talk. DNS oddities are items I collect whenever I see them, and while I knew about a good [&hellip;]","og_url":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/","og_site_name":"rud.is","article_published_time":"2023-02-27T20:34:25+00:00","og_image":[{"width":630,"height":630,"url":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2069959_1.jpg?fit=630%2C630&ssl=1","type":"image\/jpeg"}],"author":"hrbrmstr","twitter_card":"summary_large_image","twitter_misc":{"Written by":"hrbrmstr","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#article","isPartOf":{"@id":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/"},"author":{"name":"hrbrmstr","@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"headline":"&#8220;Bizarre&#8221; DNS Hacks For Fun And, Um\u2026, Fun","datePublished":"2023-02-27T20:34:25+00:00","mainEntityOfPage":{"@id":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/"},"wordCount":737,"commentCount":1,"publisher":{"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"image":{"@id":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2069959_1.jpg?fit=630%2C630&ssl=1","articleSection":["DNS","Go","Golang","hacks"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/","url":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/","name":"\"Bizarre\" DNS Hacks For Fun And, Um\u2026, Fun - rud.is","isPartOf":{"@id":"https:\/\/rud.is\/b\/#website"},"primaryImageOfPage":{"@id":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#primaryimage"},"image":{"@id":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#primaryimage"},"thumbnailUrl":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2069959_1.jpg?fit=630%2C630&ssl=1","datePublished":"2023-02-27T20:34:25+00:00","breadcrumb":{"@id":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#primaryimage","url":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2069959_1.jpg?fit=630%2C630&ssl=1","contentUrl":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2069959_1.jpg?fit=630%2C630&ssl=1","width":630,"height":630,"caption":"silhouette of a couple with \"It\u2026It was DNS\" over them"},{"@type":"BreadcrumbList","@id":"https:\/\/rud.is\/b\/2023\/02\/27\/bizarre-dns-hacks-for-fun-and-um-fun\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/rud.is\/b\/"},{"@type":"ListItem","position":2,"name":"&#8220;Bizarre&#8221; DNS Hacks For Fun And, Um\u2026, Fun"}]},{"@type":"WebSite","@id":"https:\/\/rud.is\/b\/#website","url":"https:\/\/rud.is\/b\/","name":"rud.is","description":"&quot;In God we trust. All others must bring data&quot;","publisher":{"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/rud.is\/b\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886","name":"hrbrmstr","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","url":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","contentUrl":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","width":460,"height":460,"caption":"hrbrmstr"},"logo":{"@id":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1"},"description":"Don't look at me\u2026I do what he does \u2014 just slower. #rstats avuncular \u2022 ?Resistance Fighter \u2022 Cook \u2022 Christian \u2022 [Master] Chef des Donn\u00e9es de S\u00e9curit\u00e9 @ @rapid7","sameAs":["http:\/\/rud.is"],"url":"https:\/\/rud.is\/b\/author\/hrbrmstr\/"}]}},"jetpack_featured_media_url":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/02\/2069959_1.jpg?fit=630%2C630&ssl=1","jetpack_shortlink":"https:\/\/wp.me\/p23idr-3zf","jetpack_likes_enabled":true,"jetpack-related-posts":[{"id":129,"url":"https:\/\/rud.is\/b\/2011\/02\/14\/metricon-name-server-log-data\/","url_meta":{"origin":13717,"position":0},"title":"Metricon: Name Server Log Data","author":"hrbrmstr","date":"2011-02-14","format":false,"excerpt":"Speakers: Fruhwirth, Proschinger, Lendl, Savola \"On the use of name server log data as input for security measurements\" \u00a0 CERT.at ERT coordinate sec efforts & inc resp for IT sec prblms on a national level in Austria constituted of IT company security teams and local CERTs \u00a0 Why name server\u2026","rel":"","context":"In &quot;Information Security&quot;","block_context":{"text":"Information Security","link":"https:\/\/rud.is\/b\/category\/information-security\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":9386,"url":"https:\/\/rud.is\/b\/2018\/04\/01\/more-options-for-querying-dns-from-r-with-1-1-1-1\/","url_meta":{"origin":13717,"position":1},"title":"More Options For Querying DNS From R with 1.1.1.1","author":"hrbrmstr","date":"2018-04-01","format":false,"excerpt":"You have to have been living under a rock to not know about Cloudflare's new 1.1.1.1 DNS offering. I won't go into \"privacy\", \"security\" or \"speed\" concepts in this post since that's a pretty huge topic to distill for folks given the, now, plethora of confusing (and pretty technical) options\u2026","rel":"","context":"In &quot;DNS&quot;","block_context":{"text":"DNS","link":"https:\/\/rud.is\/b\/category\/dns\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":4267,"url":"https:\/\/rud.is\/b\/2016\/04\/11\/clandestine-dns-lookups-with-gdns\/","url_meta":{"origin":13717,"position":2},"title":"Clandestine DNS lookups with gdns","author":"hrbrmstr","date":"2016-04-11","format":false,"excerpt":"Google recently [announced](https:\/\/developers.google.com\/speed\/public-dns\/docs\/dns-over-https) their DNS-over-HTTPS API, which _\"enhances privacy and security between a client and a recursive resolver, and complements DNSSEC to provide end-to-end authenticated DNS lookups\"_. The REST API they provided was pretty simple to [wrap into a package](https:\/\/github.com\/hrbrmstr\/gdns) and I tossed in some [SPF](http:\/\/www.openspf.org\/SPF_Record_Syntax) functions that I had\u2026","rel":"","context":"In &quot;APIs&quot;","block_context":{"text":"APIs","link":"https:\/\/rud.is\/b\/category\/apis\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/04\/Fullscreen_4_11_16__1_10_AM.png?fit=1173%2C1013&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/04\/Fullscreen_4_11_16__1_10_AM.png?fit=1173%2C1013&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/04\/Fullscreen_4_11_16__1_10_AM.png?fit=1173%2C1013&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/04\/Fullscreen_4_11_16__1_10_AM.png?fit=1173%2C1013&ssl=1&resize=700%2C400 2x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2016\/04\/Fullscreen_4_11_16__1_10_AM.png?fit=1173%2C1013&ssl=1&resize=1050%2C600 3x"},"classes":[]},{"id":2969,"url":"https:\/\/rud.is\/b\/2014\/04\/25\/moving-from-system-calls-to-rcpp-interfaces\/","url_meta":{"origin":13717,"position":3},"title":"Moving From system() calls to Rcpp Interfaces","author":"hrbrmstr","date":"2014-04-25","format":false,"excerpt":"Over on the [Data Driven Security Blog](http:\/\/datadrivensecurity.info\/blog\/posts\/2014\/Apr\/making-better-dns-txt-record-lookups-with-rcpp\/) there's a post on how to use `Rcpp` to interface with an external library (in this case `ldns` for DNS lookups). It builds on [another post](http:\/\/datadrivensecurity.info\/blog\/posts\/2014\/Apr\/firewall-busting-asn-lookups\/) which uses `system()` to make a call to `dig` to lookup DNS `TXT` records. The core code\u2026","rel":"","context":"In &quot;Information Security&quot;","block_context":{"text":"Information Security","link":"https:\/\/rud.is\/b\/category\/information-security\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":9392,"url":"https:\/\/rud.is\/b\/2018\/04\/02\/nykolas-z-updates-global-alternative-dns-speed-test-to-include-cloudflare-1-1-1-1\/","url_meta":{"origin":13717,"position":4},"title":"Nykolas Z Updates Global Alternative DNS Speed Test to Include Cloudflare (1.1.1.1)","author":"hrbrmstr","date":"2018-04-02","format":false,"excerpt":"A while back, Medium blogger 'Nykolas Z' posted results from a globally distributed DNS resolver test to find the speediest provider (NOTE: speed is not the only consideration when choosing an alternative DNS provider). While the test methodology is not provided (the \"scientific method\" has yet to fully penetrate \"cyber\")\u2026","rel":"","context":"In &quot;DNS&quot;","block_context":{"text":"DNS","link":"https:\/\/rud.is\/b\/category\/dns\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2018\/04\/cf-speed.png?fit=1200%2C663&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2018\/04\/cf-speed.png?fit=1200%2C663&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2018\/04\/cf-speed.png?fit=1200%2C663&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2018\/04\/cf-speed.png?fit=1200%2C663&ssl=1&resize=700%2C400 2x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2018\/04\/cf-speed.png?fit=1200%2C663&ssl=1&resize=1050%2C600 3x"},"classes":[]},{"id":12225,"url":"https:\/\/rud.is\/b\/2019\/05\/26\/two-new-ways-to-make-dns-over-https-queries-in-r\/","url_meta":{"origin":13717,"position":5},"title":"Two New Ways to Make DNS over HTTPS Queries in R","author":"hrbrmstr","date":"2019-05-26","format":false,"excerpt":"A fair bit of time ago the {gdns} package made its way to CRAN to give R users the ability to use Google's (at that time) nascent support for DNS over HTTPS (DoH). A bit later on Cloudflare also provided a global DoH endpoint and that begat the (not-on-CRAN) {dnsflare}\u2026","rel":"","context":"In &quot;DNS&quot;","block_context":{"text":"DNS","link":"https:\/\/rud.is\/b\/category\/dns\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts\/13717","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/comments?post=13717"}],"version-history":[{"count":0,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts\/13717\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/media\/13724"}],"wp:attachment":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/media?parent=13717"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/categories?post=13717"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/tags?post=13717"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}