DNS Esoterica – Why you can't dig Switzerland
shkspr.mobi
shkspr.mobi
Reminds me so much of the way "smart" telecom engineers bastardized SS7 to ship new features onto legacy telco infrastructure. SS7 is like 20M lines of C. You can't really change it without breaking it in many other places, AT&T used to have a metric which was something like "for every 10 lines of code you alter in SS7, you create 8 bugs in other parts of the code." So "smart" telecom engineers would take existing fields in the SS7 logic and use them for different functions inside of their telco. A billing field could instead be used as a feature flag for some sort of customer state, but only inside of the telco's network (and re-written back to the compliant SS7 standard when the data was headed out of the network). This was called encapsulation and wrapping and un-wrapping packets just in time was the source of many many problems in my telecom life.
Just in time editing of network packets at the boundary is always fun. Most of the problems that would happen would come from forgetting to rewrite back to SS7 and transmitting the internal codes out.
This is the dirty truth. What we think of as telco is evolving. Telco is desperately trying not to be a “dumb pipe”, but that’s exactly what the internet wants the base layer to be. When the base layer is opinionated, bad things happen, like net neutrality.
What we want is unbiased fast networks that route data indiscriminately as long as it is correctly formatted and sent from a known address. That’s it.
Everything else is just vanity.
Totally agree with the what we want part.
Not wrappers. VoLTE is literally SIP with extensions. And VoWiFi is literally VoLTE over IPSec/IKE with EAP auth, so SIP over IPSec. Really just bog standard stuffs.
> – pretty complex, but still using modern tech
Not sure about "modern", but yeah pretty much every actor uses SIP one way or another. It does have a few old stuff (one SIP extension of VoLTE is to allow SIP-negotiated IPSec tunnel. For HMAC it supports md5-96 and sha1-96 and that's all.), but nothing that makes you scream of over-complication.
WhatsApp really applied a ton of pressure to telcos and changed the game. Do you remember they an international sms in the US was $.60 per message before whatsapp?
dig -q ch -t NS
instead of dig ch NS
Using the options eliminates any possibility of misinterpretations like this. dig ch NS IN +short
dig -q ch -t NS -c IN +short
dig uk NS IN +short
dig -q uk -t NS -c IN +short
Only when using the first form do you get a comment ";; Warning, extra class option" and the incorrect results. So even when using the full pattern of un-argumented options as outlined in the man page, it fails to work as expected specifically for ch.Long story short:
Someone entered some characters erroneously in the Unicode spec and now those characters are there FOREVER.
The fact that no-one necessarily knows how to read them aloud (some of them you can guess, some of them are very unclear) can be a fun wrinkle.
There was a time when these records were handy — I was pretty excited when I could connect directly from my desktop machine at PARC to a host at the AI lab on the MIT chaosnet. Before the ARPANET transitioned to TCP I had to manually hop through a couple of protocol gateways to make connections like these. Afterwards it was transparent.
BTW CHAOS used strings to identify ports/protocols rather than reserved numbers. So there is a lot you can store in a compliant implementation of the DNS.
* Also the bane of some high school classes, but that’s quite another matter.
Probably because you are maybe one of a few hundreds of people who have made use of this (and it was decades ago), out of the billions of people who have used the internet.
Cool story though.
Weirdly I did actually implement a Hesiod plugin for macOS once, it never shipped though.
> The IN and CH class names overlap with the IN and CH top level domain names. Either use the -t and -c options to specify the type and class, use the -q the specify the domain name, or use "IN." and "CH." when looking up these top level domains.
Off-topic: I got excited when I saw the nicely coloured output from dig which makes it more readable. I thought that maybe the author has some new version that’s not yet available on Ubuntu LTS. Unfortunately, the nice colours are from judicious use of highlight.js¹ – one good reason to have uMatrix configured to allow first-party JavaScript!
There's also stuff like this, which will postprocess & color output from any command: https://github.com/garabik/grc, or https://github.com/armandino/TxtStyle
I then use the WordPress WebMention plugin - https://github.com/pfefferle/wordpress-webmention - to render them nicely.
Seems similar to the problem on YAML's Norway (https://hitchdev.com/strictyaml/why/implicit-typing-removed/) and the Turkish Lira (TRY) problem (https://devblogs.microsoft.com/oldnewthing/20190912-00/?p=10...)
side note: Not thicknet, but I do have thinnet still running here although that only carries IPX/SPX and some TCP/IP :-D
Hey, what ever you’ve got at layer 1 (thick eyes, thinner, 10baseT) the next layer up is Ethernet!
> I do have thinnet…
There must have been chaosnet over thinnet that I just don’t remember.
But since you have thinnet you should drop some pups on there so your Altos can talk to each other. Get your mail via Grapevine (still superior to IMAP)… have some fun!
From the grammar in RFC 1035:
<domain-name><rr> [<comment>]
<blank><rr> [<comment>]
<rr> contents take one of the following forms:
[<TTL>] [<class>] <type> <RDATA>
[<class>] [<TTL>] <type> <RDATA>
All the columns being optional creates the ambiguity between the <class> and <domain-name> columns in the TTL missing/2nd form. In the real world <class> is always "IN". It's even worse since the set of <type>'s is unbounded and the <RDATA> grammar depends on <type>I believe this is one reason why tinydns has its own format https://cr.yp.to/djbdns/tinydns-data.html
Back in the 80s there were not many examples of configuration files, so everybody just invented their own idiosyncratic format. Most of those old formats have long since died off, but a few have survived to haunt us even today.
but there really should be some sort of charity foundation to help the victims of sendmail.cf trauma.
I believe one of the first BSD versions containing sendmail (by Eric Allman) is this one: https://github.com/weiss/original-bsd/blob/bd282c88c1b3c2575... (almost 40 years ago!)
Its a little hard to read due to the format, but here's some explanation of the (1983, earliest?) config file that was used back then: https://github.com/weiss/original-bsd/blob/bd282c88c1b3c2575...
From what I grasp, it started as an extensive dynamic parser that needed to understand a lot of rules, and I guess with each new RFC and version, the rules needed to be extended too. And the config file could be loaded into a memory image to improve performance.
You may have to rtfm, but only once.
https://github.com/PowerDNS/pdns/blob/master/pdns/zoneparser...
And in BIND where the <rdata> parsing is coded up for a bunch of <type>'s:
https://github.com/isc-projects/bind9/tree/main/lib/dns/rdat...
Regarding zone transfers, I think it makes sense that the AXFR and IXFR protocols are specified in RFCs. Neither the server nor client should care about what software is used by the other host to implement the agreed protocols.
There’s nothing wrong with it in the same way there was nothing wrong with telnet or ftp.
That feature was added well over a decade ago. Your changes on the primary will be replicated (within seconds) to your secondaries.
I’m glad axfr works for you and you’re happy with it. I stopped using bind after a multitude of security issues it had over the years and I haven’t looked back. When I did used to use it, I switched to rsync for zone files probably sometime around 2000.
All of this is completely besides my original point: the zone file format needn’t have been an RFC, and probably not AXFR either. As far as I’m aware, no other RFC specifies implementation-specific decisions like the DNS RFCs do. It would be as if the sendmail.cf format had an RFC. AXFR is idiosyncratic and as recently as a decade ago underspecified:
https://datatracker.ietf.org/doc/html/rfc5936
And it looks like there’s still ongoing work to make it secure:
class=value
Change the query class to one of:
IN
the Internet class
CH
the Chaos class
HS
the Hesiod class
ANY
wildcard
Man pages have amazing nuggets of history in them if one chooses to dig in! dig . NS
to get the root nameserversI recall (All) DNS Resource Records listed [1], which is another treasure of historical tidbits.
A 35 year old protocol has a lot of vestigial bits, but still vital to network operations.
dig Esoterica*
Every time I see the headline, that's how I first read it.
I wonder if I'll ever grow up.
https://en.wikipedia.org/wiki/Hesiod_(name_service)
which is from Project Athena:
https://en.wikipedia.org/wiki/Project_Athena
> Project Athena was a joint project of MIT, Digital Equipment Corporation, and IBM to produce a campus-wide distributed computing environment for educational use.
dig ch. ns
dig in. ns
Both return the expected results.While this is a fully qualified domain name:
www.example.com
This is the actual domain name: www.example.com.
The linked article and doesn't really explain why someone should add the trailing dot to the hostname. I do: It's the name of the root DNS zone and unambiguously identifies the `dig` parameter as a hostname.When querying the DNS you specify the class of address you want (IN, CH, whatever) and the resolver returns you the corresponding record. So if a host has a connection to an IP network and an Chaosnet network then it would have two entwork identities and its DNS zone would contain both classes of ID.
Obviously IN is really the only network class that is used now, but these things persist in old code.
Hobbyist Chaos network: http://chaosnet.net/
Trying doing this to see a DNS server's version:
dig ch txt version.bind @9.9.9.9
Try doing this to see the hostname of a DNS server servicing your request: dig ch txt id.server @9.9.9.9/bin is a directory called bin
/ is the root directory
/root is a directory called "root" based in the root directory
Did you get that?
Simples, now you see, dns is the same thing backwards with dots...
All that before user gets to type "www.google.com."
Interestingly, in China people just type a single word and the default search engine does the thinking. Giving them power that google.com can only dream of. ;)