Created
July 11, 2019 23:32
-
-
Save nlyan/2a958fa476182e1b07955a945f0d7052 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RFCs | |
==== | |
RFC 1035 : Domain names - implementation and specification, November 1987 | |
RFC 2181 : Clarifications to the DNS Specification, July 1997 | |
- defines an "RRSet" as combination of class, name and type. | |
- deprecates differing TTLs within an RRSet, says should be treated as | |
an error. | |
- defines the "origin" as the child name just below the zone cut: | |
"The name of the zone is the same as the name of the domain | |
at the zone's origin." | |
- mentions lack of authority over cutting NS records | |
- specifies that the TTL is an unsigned number, but between 0 and | |
2147483647 inclusive... if bit 31 is set, it must be regarded to be 0 | |
- clarifies CNAMEs... | |
- labels... 1 - 63 bytes | |
- FQDNs... 255 bytes incl separators. | |
- clarifies that binary is cool. | |
- the whole "name syntax" section is super important to ZFP | |
"A DNS server may be | |
configurable to issue warnings when loading, or even to refuse to | |
load, a primary zone containing labels that might be considered | |
questionable, however this should not happen by default." | |
RFC 2308 : | |
What the TTL field in SOA means, $TTL | |
RFC 2540 : | |
- $DATE | |
RFC 2673 : Binary Labels in the Domain Name System, August 1999 | |
- Historic, not adopted. BIND errors on [bitstrings] in zone files now | |
RFC 4027 : Domain Name System Media Types - 2005 | |
- Establishes "text/dns" as the zone MIME type. | |
- Notes that " The encoding of detached DNS | |
information is, unlike textual master files, well defined." | |
- talks more about master file fugly and how using \DDD is recommended | |
- "Interoperability considerations" on page 2, section 3 | |
RFC 3597 : Handling of Unknown DNS Resource Record (RR) Types, Sep 2003 | |
- Section 5, 6... damn | |
********************************************* | |
********************************************* | |
RFC 4343 : DNS Case Insensitivity Clarification, January 2006 | |
2.1. Escaping Unusual DNS Label Octets... super useful | |
"It is advisable to | |
avoid using a backslash to quote an immediately following non- | |
printing ASCII character code to avoid implementation difficulties." | |
... applies to all classes | |
[4.2] "When a node in the DNS name tree is created by any of such | |
inputs, no case conversion is done. Thus, the case of ASCII labels | |
is preserved if they are for nodes being created. " | |
... mentions RNAME case should be preserved because of foo in [email protected] | |
"Further interoperability | |
issues with unrecognized RR types exist, which may be handled as | |
discussed in section 5 of RFC 3597 [8]." | |
RFC 7553 wants quoted RDATA longer than 255 bytes (for URIs) | |
Zone file notes, and differences between Bind and ldns. | |
======================================================= | |
- Parens *inside* tokens are allowed, e.g. "foo(bar". In Bind they effectively | |
terminate the current token, and immediately start a second, producing | |
"foo" & "bar". In essence, "foo(bar" is parsed like the same as "foo( bar" | |
and "foo (bar" | |
ldns, on the other hand, produces "foobar". The parens are omitted, and | |
processed correctly as control characters, but only a single token is | |
emitted. | |
This means Bind will parse "foobar.com. A(8.8.8.8)", whereas ldns will | |
treat "A8.8.8.8" as the record type. | |
- ldns accepts tok"en, i.e. unescaped double quotes inside unquoted tokens. | |
- Line breaks inside double quoted strings are treated differently. | |
Neither require carriage returns to be escaped, even though Bind does | |
parse zone files with CR line-endings, whereas ldns does not. | |
Bind requires line-feeds to be escaped, ldns does not. ldns in fact | |
randomly converts \n to a space (0x20). | |
ldns also converts \r and \r\n to a space and double space, respectively. | |
In Bind, a single slash cannot escape an entire \r\n sequence (presumably | |
because the backslash needlessly escapes the carriage return, not the | |
line-feed which actually needs escaping). I guess if you're on Windows | |
and you want to create a TXT record containing a line break, you have to | |
go ahead and type "foo\013\010bar" | |
- Both Bind and ldns allow '(' in column 0, but Bind then refuses | |
to accept any form of whitespace to form the "previous name" placeholder. | |
ldns will accept a space or tab, but not a lone line break. This is sort of | |
unusual in that, elsewhere, when inside parens, line breaks (with or | |
without an attached end-of-line comment) are treated as token delimiters. | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment