1 DNS Extensions Working Group Edward Lewis
2 INTERNET-DRAFT NeuStar, Inc.
3 Expires: Octopber 1, 2009 April 2009
4 Updates: 1034, 1035 (if approved)
5 Intended status: Standards Track
7 DNS Zone Transfer Protocol (AXFR)
8 draft-ietf-dnsext-axfr-clarify-11.txt
12 This Internet-Draft is submitted to IETF in full conformance with the
13 provisions of BCP 78 and BCP 79.
15 Internet-Drafts are working documents of the Internet Engineering
16 Task Force (IETF), its areas, and its working groups. Note that
17 other groups may also distribute working documents as Internet-
20 Internet-Drafts are draft documents valid for a maximum of six months
21 and may be updated, replaced, or obsoleted by other documents at any
22 time. It is inappropriate to use Internet-Drafts as reference
23 material or to cite them other than as "work in progress."
25 The list of current Internet-Drafts can be accessed at
26 http://www.ietf.org/1id-abstracts.html
28 The list of Internet-Draft Shadow Directories can be accessed at
29 http://www.ietf.org/shadow.html
31 This Internet-Draft will expire on October 1, 2009.
35 Copyright (c) 2009 IETF Trust and the persons identified as the
36 document authors. All rights reserved.
38 This document is subject to BCP 78 and the IETF Trust's Legal
39 Provisions Relating to IETF Documents
40 (http://trustee.ietf.org/license-info) in effect on the date of
41 publication of this document. Please review these documents
42 carefully, as they describe your rights and restrictions with
43 respect to this document.
47 The Domain Name System standard mechanisms for maintaining coherent
48 servers for a zone consist of three elements. One mechanism is the
49 Authoritative Transfer (AXFR) is defined in RFC 1034 and RFC 1035.
50 The definition of AXFR, has proven insufficient in detail, forcing
51 implementations intended to be compliant to make assumptions, impeding
52 interoperability. Yet today we have a satisfactory set of
53 implementations that do interoperate. This document is a new
54 definition of the AXFR, new in the sense that is it recording an
55 accurate definition of an interoperable AXFR mechanism.
59 The Domain Name System standard facilities for maintaining coherent
60 servers for a zone consist of three elements. Authoritative
61 Transfer (AXFR) is defined in "Domain Names - Concepts and Facilities"
62 [RFC1034] (referred to in this document as RFC 1034) and "Domain Names
63 - Implementation and Specification" [RFC1035] (aka RFC 1035).
64 Incremental Zone Transfer (IXFR) is defined in "Incremental Zone
65 Transfer in DNS" [RFC1995]. A mechanism for prompt notification of
66 zone changes (NOTIFY) is defined in "A Mechanism for Prompt
67 Notification of Zone Changes (DNS NOTIFY)" [RFC1996]. The goal of
68 these mechanisms is to enable a set of DNS name servers to remain
69 coherently authoritative for a given zone.
71 Comments on this draft ought to be addressed to the editor or to
72 namedroppers@ops.ietf.org.
74 1.1 Definition of Terms
76 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
77 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
78 document are to be interpreted as described in "Key words for use in
79 RFCs to Indicate Requirement Levels" [BCP14].
81 "Newer"/"New" DNS and "older"/"old" DNS refers to implementations
82 written after and prior to the publication of this document.
86 In the greater context there are many ways to achieve coherency among
87 a set of name servers. The AXFR, IXFR and NOTIFY mechanisms form
88 just one, the one defined in the RFCs cited. For example, there are
89 DNS implementations that assemble answers from data stored in
90 relational databases (as opposed to master files) relying on the
91 database's non-DNS means to synchronize the database instances. Some
92 of these non-DNS solutions interoperate in some fashion. As far as
93 it is known, AXFR, IXFR and NOTIFY are the only in-band mechanisms
94 that provide an interoperable solution to the desire for coherency
95 within the definition of DNS, they certainly are the only mechanisms
96 documented by the IETF.
98 This document does not cover incoherent DNS situations. There are
99 applications of the DNS in which servers for a zone are designed to be
100 incoherent. For these configurations, a coherency mechanism as
101 described here would be unsuitable.
103 "General purpose DNS implementation" refers to DNS software developed
104 for wide-spread use. This includes resolvers and servers freely
105 accessible as libraries and standalone processes. This also includes
106 proprietary implementations used only in support of DNS service
109 "Turnkey DNS implementation" refers to custom made, single use
110 implementations of DNS. Such implementations consist of software
111 that employs the DNS protocol message format yet do not conform to
112 the entire range of DNS functionality.
114 A DNS implementation is not required to support AXFR, IXFR and NOTIFY.
115 A DNS implementation SHOULD have some means for maintaining name server
116 coherency. A general purpose DNS implementation SHOULD include AXFR
117 (and in the same vein IXFR and NOTIFY), but turnkey DNS implementations
118 MAY exist without AXFR. (An editorial note to readers of this section.
119 The mention of IXFR and NOTIFY is for context and illustration, this
120 document does not make any normative comments on those mechanisms.)
124 Besides describing the mechanisms themselves, there is the context in
125 which they operate to consider. When AXFR, IXFR and NOTIFY were
126 defined, there was little consideration given to security and privacy
127 issues. Since the original definition of AXFR, new opinions have
128 appeared on the access to an entire zone's contents. In this document,
129 the basic mechanisms will be discussed separately from the permission
130 to use these mechanisms.
132 1.4 Coverage and Relationship to Original AXFR Specification
134 This document concentrates on just the definition of AXFR. Any effort
135 to update the IXFR or NOTIFY mechanisms would be done in different
138 The original "specification" of the AXFR sub-protocol is scattered
139 through RFC 1034 and RFC 1035. Section 2.2 of RFC 1035 on page 5
140 depicts the scenario for which AXFR has been designed. Section 4.3.5
141 of RFC 1034 describes the zone synchronization strategies in general
142 and rules for the invocation of a full zone transfer via AXFR; the
143 fifth paragraph of that section contains a very short sketch of the
144 AXFR protocol; Section 5.5 of RFC 2181 has corrected a significant
145 flaw in that specification. Section 3.2.3 of RFC 1035 has assigned
146 the code point for the AXFR QTYPE (see section 2.1.2 below for more
147 details). Section 4.2 of RFC 1035 discusses the transport layer use
148 of DNS and shortly explains why UDP transport is deemed inappropriate
149 for AXFR; the last paragraph of Section 4.2.2 gives details for the
150 TCP connection management with AXFR. Finally, the second paragraph
151 of Section 6.3 in RFC 1035 mandates server behavior when zone data
152 changes occur during an ongoing zone transfer using AXFR.
154 This document will update the specification of AXFR in fully
155 specifying the record formats and processing rules for AXFR, largely
156 expanding on paragraph 5 of Section 4.3.5 of RFC 1034, and detailing
157 the transport considerations for AXFR, thus amending Section 4.2.2 of
158 RFC 1035. Furthermore, it discusses backward compatibility issues
159 and provides policy/management considerations as well as specific
160 Security Considerations for AXFR. The goal of this document is to
161 define AXFR as it exists, or is supposed to exist, currently.
165 An AXFR session consists of an AXFR query message and the sequence of
166 AXFR response messages returned for it. In this document, the AXFR
167 client is the sender of the AXFR query and the AXFR server is the
168 responder. (Use of terms such as master, slave, primary, secondary
169 are not important to defining AXFR.) The use of the word "session"
170 without qualification refers to an AXFR session.
172 An important aspect to keep in mind is that the definition of AXFR is
173 restricted to TCP [RFC0793]. The design of the AXFR process has
174 certain inherent features that are not easily ported to UDP [RFC0768].
176 The basic format of an AXFR message is the DNS message as defined in
177 RFC 1035, Section 4 ("MESSAGES") [RFC1035], updated by the following:
178 - "A Mechanism for Prompt Notification of Zone Changes (...)" [RFC1996]
179 - "Domain Name System (DNS) IANA Considerations" [RFC5395]
180 - "Dynamic Updates in the Domain Name System (DNS UPDATE)" [RFC2136]
181 - "Clarifications to the DNS Specification" [RFC2181]
182 - "Extension Mechanisms for DNS (EDNS0)" [RFC2671]
183 - "Secret Key Transaction Authentication for DNS (TSIG)" [RFC2845]
184 - "Secret Key Establishment for DNS (TKEY RR)" [RFC2930]
185 - "Obsoleting IQUERY" [RFC3425]
186 - "Handling of Unknown DNS Resource Record (RR) Types" [RFC3597]
187 - "Resource Records for the DNS Security Extensions" [RFC4034]
188 - "Protocol Modifications for the DNS Security Extensions" [RFC4035]
189 - "Use of SHA-256 in DNSSEC ... (DS) ... (RRs)" [RFC4509]
190 - "HMAC SHA TSIG Algorithm Identifiers" [RFC4635]
191 - "... (DNSSEC) Hashed Authenticated Denial of Existence" [RFC5155]
193 For completeness, the following, in process, documents contain
194 information about the DNS message. These documents ought not interfere
195 with AXFR but these documents are helpful in understanding what will
198 - "Use of SHA-2 algorithms with RSA in DNSKEY and RRSIG Resource
199 Records for DNSSEC" [DRAFT1]
200 - "Clarifications and Implementation Notes for DNSSECbis" [DRAFT2]
202 The upper limit on the permissible size of a DNS message over TCP is
203 only restricted by the TCP framing defined in RFC 1035, section 4.2.2
204 which specifies a two-octet message length field, understood to be
205 unsigned, and thus causing a limit of 65535 octets. Unlike DNS
206 messages over UDP, this limit is not changed by EDNS0.
208 Note that the TC (truncation) bit is never set by an AXFR server nor
209 considered/read by an AXFR client.
211 Field names used in this document will correspond to the names as they
212 appear in the IANA registry for DNS Header Flags [DNSFLGS].
216 An AXFR query is sent by a client whenever there is a reason to ask.
217 This might be because of zone maintenance activities or as a result of
218 a command line request, say for debugging.
220 An AXFR query is sent by a client whenever there is a reason to ask.
221 This might be because of scheduled or triggered zone maintenance
222 activities (see section 4.3.5 of RFC 1034 and DNS NOTIFY [RFC1996],
223 respectively) or as a result of a command line request, say for
228 These are the DNS message header values for an AXFR query.
232 OPCODE MUST be 0 (Standard Query)
240 RCODE MUST be 0 (No error)
244 ARCOUNT See note 2.1.1.d
246 Note 2.1.1.a Set to any value that the client is not already using
247 with the same server. There is no specific means for selecting the
248 value in this field. (Recall that AXFR is done only via TCP
251 A server MUST reply using messages that use the same message ID to
252 allow a client to meaningfully have multiple AXFR queries outstanding.
254 Note 2.1.1.b The value in this field has no meaning in the context of
255 AXFR query messages. For the client, it is RECOMMENDED that the
256 value be zero. The server MUST ignore this value.
258 Note 2.1.1.c The client MUST set this bit to 0, the server MUST ignore
261 Note 2.1.1.d The client MUST set this field to be the number of
262 resource records appearing in the additional section. See Section
263 2.1.5 "Additional Section" for details.
265 The value MAY be 0, 1 or 2. If it is 2, the additional
266 section MUST contain both an EDNS0 [RFC2671] OPT resource record and
267 a record carrying transaction integrity and authentication data,
268 currently a choice of TSIG [RFC2845] and SIG(0) [RFC2931]. If the
269 value is 1, then the additional section MUST contain either only an
270 EDNS0 OPT resource record or a record carrying transaction integrity
271 and authentication data. If the value is 0, the additional section
276 The Query section of the AXFR query MUST conform to section 4.1.2 of
277 RFC 1035, and contain the following values:
279 QNAME the name of the zone requested
280 QTYPE AXFR(= 252), the pseudo-RR type for zone transfer [DNSVALS]
281 QCLASS the class of the zone requested
287 2.1.4 Authority Section
291 2.1.5 Additional Section
293 The client MAY include an EDNS0 OPT [RFC2671] resource record. If the
294 server has indicated that it does not support EDNS0, the client MUST
295 send this section without an EDNS0 OPT resource record if there is a
296 retry. Indication that a server does not support EDNS0 is not an
297 explicit element in the protocol, it is up to the client to interpret.
298 Most likely, the server will return a FORMERR which might be related to
299 the OPT resource record.
301 The client MAY include a transaction integrity and authentication
302 resource record, currently a choice of TSIG [RFC2845] or SIG(0)
303 [RFC2931]. If the server has indicated that it does not recognize the
304 resource record, and that the error is indeed caused by the resource
305 record, the client probably ought not try again. Removing the security
306 data in the face of an obstacle ought to only be done with full
307 awareness of the implication of doing so.
309 In general, if an AXFR client is aware that an AXFR server does not
310 support a particular mechanism, the client SHOULD NOT attempt to engage
311 the server using the mechanism (or at all). A client could become
312 aware of a server's abilities via a configuration setting or via some
313 other (as yet) undefined means.
315 The range of permissible resource records that MAY appear in the
316 additional section might change over time. If either a change to an
317 existing resource record (like the OPT RR for EDNS0) is made or
318 a new additional section record is created, the new definitions ought
319 to include a discussion on the impact upon AXFR. Although this is not
320 predictable, future additional section residing records may have an
321 effect that is orthogonal to AXFR, so can ride through the session as
322 opaque data. In this case, a "wise" implementation ought to be able
323 to pass these records through without disruption.
327 The AXFR response will consist of 0 or more messages. A "0 message"
328 response is covered in section 2.2.1.
330 An AXFR response that is transferring the zone's contents will consist
331 of a series (which could be a series of length 1) of DNS messages.
332 In such a series, the first message MUST begin with the SOA
333 resource record of the zone, the last message MUST conclude with the
334 same SOA resource record. Intermediate messages MUST NOT contain the
335 SOA resource record. The first message MUST copy the Query Section
336 from the corresponding AXFR query message in to the first response
337 message's query section. Subsequent messages MAY do the same.
339 An AXFR response that is indicating an error MUST consist of a single
340 DNS message with the return code set to the appropriate value for the
341 condition encountered - once the error condition is detected. Such
342 a message MUST terminate the AXFR session; it MUST copy the Query
343 Section from the AXFR query into its Query Section, but the inclusion
344 of the terminating SOA resource record is not necessary.
346 An AXFR client might receive a number of AXFR response messages
347 free of an error condition before the message indicating an error
350 2.2.1 "0 Message" Response
352 A legitimate "0 message" response, i.e., the client sees no response
353 whatsoever, is very exceptional and controversial. Unquestionably it
354 is unhealthy for there to be 0 responses in a protocol that is designed
355 around a query - response paradigm over an unreliable transport. The
356 lack of a response could be a sign of underlying network problems and
357 cause the protocol state machine to react accordingly. However, AXFR
358 uses TCP and not UDP, eliminating undetectable network errors.
360 A "0 message response" is reserved for situations in which the server
361 has a reason to suspect that the query is sent for the purpose of
362 abuse. Due to the use of this being so controversial, a "0 message
363 response" is not being defined as a legitimate part of the protocol
364 but the use of it is being acknowledged as a warning to AXFR client
365 implementations. Any earnest query has the expectation of some
366 response but may not get one.
371 QR MUST be 1 (Response)
372 OPCODE MUST be 0 (Standard Query)
374 TC MUST be 0 (Not truncated)
375 RD RECOMMENDED copy request's value, MAY be set to 0
380 RCODE See note 2.2.2.f
381 QDCOUNT MUST be 1 in the first message; MUST be 0 or 1 in all
383 ANCOUNT See note 2.2.2.g
385 ARCOUNT See note 2.2.2.h
387 Note 2.2.2.a Because some old implementations behave differently than
388 is now desired, the requirement on this field is stated in detail.
389 New DNS servers MUST set this field to the value of the AXFR query
390 ID in each AXFR response message for the session. AXFR clients MUST
391 be able to manage sessions resulting from the issuance of multiple
392 outstanding queries, whether AXFR queries or other DNS queries. A
393 client SHOULD discard responses that do not correspond (via the
394 message ID) to any outstanding queries.
396 Unless the client is sure that the server will consistently set the ID
397 field to the query's ID, the client is NOT RECOMMENDED to issue any
398 other queries until the end of the zone transfer. A client MAY become
399 aware of a server's abilities via a configuration setting.
401 Note 2.2.2.b If the RCODE is 0 (no error), then the AA bit MUST be 1.
402 For any other value of RCODE, the AA bit MUST be set according to rules
403 for that error code. If in doubt, it is RECOMMENDED that it be set
404 to 1. It is RECOMMENDED that the value be ignored by the AXFR client.
406 Note 2.2.2.c It is RECOMMENDED that the server set the value to 0,
407 the client MUST ignore this value.
409 The server MAY set this value according to the local policy regarding
410 recursive service, but doing so might confuse the interpretation of the
411 response as AXFR can not be retrieved recursively. A client MAY note
412 the server's policy regarding recursive service from this value, but
413 SHOULD NOT conclude that the AXFR response was obtained recursively
414 even if the RD bit was 1 in the query.
416 Note 2.2.2.d The server MUST set this bit to 0, the client MUST ignore
419 Note 2.2.2.e If the implementation supports the DNS Security Extensions
420 (see below) then this value MUST be set according to the rules in RFC
421 4035, section 3.1.6, "The AD and CD Bits in an Authoritative Response".
422 If the implementation does not support the DNS Security Extensions,
423 then this value MUST be set to 0 and MUST be ignored upon receipt.
425 The DNS Security Extensions (DNSSEC) is defined in these base
427 - "DNS Security Introduction and Requirements" [RFC4033]
428 - "Resource Records for the DNS Security Extensions" [RFC4034]
429 - "Protocol Modifications for the DNS Security Extensions" [RFC4035]
430 - "Use of SHA-256 in DNSSEC Delegation Signer RRs" [RFC4509]
431 - "DNS Security Hashed Authenticated Denial of Existence" [RFC5155]
433 as well pending documents, such as these:
435 - "Use of SHA-2 algorithms with RSA in DNSKEY and RRSIG Resource
436 Records for DNSSEC" [DRAFT1]
437 - "Clarifications and Implementation Notes for DNSSECbis" [DRAFT2]
439 Note 2.2.2.f In the absence of an error, the server MUST set the value
440 of this field to NoError. If a server is not authoritative for the
441 queried zone, the server SHOULD set the value to NotAuth. (Reminder,
442 consult the appropriate IANA registry [DNSVALS].) If a client
443 receives any other value in response, it MUST act according to the
444 error. For example, a malformed AXFR query or the presence of an EDNS0
445 OPT resource record sent to an old server will garner a FormErr value.
446 This value is not set as part of the AXFR-specific response processing.
447 The same is true for other error-indicating values.
449 Note 2.2.2.g The count of answer records MUST equal the number of
450 resource records in the AXFR Answer Section. When a server is aware
451 that a client will only accept one resource record per response
452 message, then the value MUST be 1. A server MAY be made aware of a
453 client's limitations via configuration data.
455 Note 2.2.2.h The client MUST set this field to be the number of
456 resource records appearing in the additional section. The
457 considerations in Note 2.1.1.d above apply equally; see Section
458 2.2.6 "Additional Section" below for more details.
462 In the first response message, this section MUST be copied from the
463 query. In subsequent messages, this section MAY be copied from the
464 query or it MAY be empty. The content of this section MAY be used to
465 determine the context of the message, that is, the name of the zone
470 MUST be populated with the zone contents. See later section on
471 encoding zone contents.
473 2.2.5 Authority Section
477 2.2.6 Additional Section
479 The contents of this section MUST follow the guidelines for EDNS0,
480 TSIG, SIG(0), or what ever other future record is possible here. The
481 contents of section 2.1.5 apply here as well.
483 2.3 TCP Connection Aborts
485 If an AXFR client sends a query on a TCP connection and the connection
486 is closed at any point, the AXFR client MUST consider the AXFR session
487 terminated. The message ID MAY be used again on a new connection,
488 even if the question and AXFR server are the same. Facing a dropped
489 connection a client SHOULD try to make some determination whether the
490 connection closure was the result of network activity or a decision
491 by the AXFR server. This determination is not an exact science. It
492 is up to the AXFR client implementor to react, but the reaction
493 SHOULD NOT be an endless cycle of retries nor an increasing (in
494 frequency) retry rate.
496 An AXFR server implementor SHOULD take into consideration the dilemma
497 described above when a connection is closed with an outstanding query
498 in the pipeline. For this reason, a server ought to reserve this
499 course of action for situations in which it believes beyond a doubt
500 that the AXFR client is attempting abusive behavior.
504 The objective of the AXFR session is to request and transfer the
505 contents of a zone. The objective is to permit the AXFR client to
506 reconstruct the zone as it exists at the server for the given zone
507 serial number. Over time the definition of a zone has evolved from
508 denoting a static set of records to also cover a dynamically updated
509 set of records, and then a potentially continually regenerated set of
512 3.1 Records to Include
514 In the answer section of AXFR response messages the resource records
515 within a zone for the given serial number MUST appear. The definition
516 of what belongs in a zone is described in RFC 1034, Section 4.2, "How
517 the database is divided into zones", in particular, section 4.2.1,
518 "Technical considerations", and it has been clarified in Section 6 of
521 Unless the AXFR server knows that the AXFR client is old and expects
522 just one resource record per AXFR response message, an AXFR server
523 SHOULD populate an AXFR response message with as many complete
524 resource record sets as will fit within a DNS message.
526 Zones for which it is impractical to list the entire zones for a serial
527 number are not suitable for AXFR retrieval. A typical (but not
528 limiting) description of such a zone is a zone consisting of responses
529 generated via other database lookups and/or computed based upon ever
532 3.2 Delegation Records
534 In RFC 1034, section 4.2.1, this text appears (keep in mind that the
535 "should" in the quotation predates [BCP14], cf. section 1.1) "The RRs
536 that describe cuts ... should be exactly the same as the corresponding
537 RRs in the top node of the subzone." There has been some controversy
538 over this statement and the impact on which NS resource records are
539 included in a zone transfer.
541 The phrase "that describe cuts" is a reference to the NS set and
542 applicable glue records. It does not mean that the cut point and apex
543 resource records are identical. For example, the SOA resource record
544 is only found at the apex. The discussion here is restricted to just
545 the NS resource record set and glue as these "describe cuts".
547 DNSSEC resource records have special specifications regarding their
548 occurrence at a zone cut and the apex of a zone. This has for the
549 first time been described in Sections 5.3 ff. and 6.2 of RFC 2181
550 (for the initial specification of DNSSEC), which now is historical.
551 The current DNSSEC core document set (see Note 2.2.2.e above) gives
552 the full details for DNSSEC(bis) resource record placement, and
553 Section 3.1.5 of RFC 4035 normatively specifies their treatment during
554 AXFR; the alternate NSEC3 resource record defined later in RFC 5155
555 behaves identically as the NSEC RR, for the purpose of AXFR.
558 o The DS RRSet only occurs at the parental side of a zone cut and is
559 authoritative data in the parent zone, not the secure child zone.
560 o The DNSKEY RRSet only occurs at the APEX of a signed zone and is
561 authoritative part of the zone it serves.
562 o Independent RRSIG RRSets occur at the signed parent side and of a
563 zone cut and at the apex of a signed zone; they are authoritative
564 part of the respective zone; simple queries for RRSIG resource
565 records may return bth RRSets at once if the same server is
566 authoritative for the parent zone and the child zone (Section
567 3.1.5 of RFC 4035 describes how to distinguish these RRs); this
568 seeming ambiguity does not occur for AXFR, since each such RRSIG
569 RRset belongs to a single zone.
570 o Different NSEC [RFC4034] or NSEC3 [RFC5155] resource records
571 equally may occur at the parental siede of a zone cut and at the
572 apex of a zone; each such resource record belongs to exactly one
573 of these zones and is to be included in the AXFR of that zone.
575 The issue is that in operations there are times when the NS resource
576 records for a zone might be different at a cut point in the parent and
577 at the apex of a zone. Sometimes this is the result of an error and
578 sometimes it is part of an ongoing change in name servers. The DNS
579 protocol is robust enough to overcome inconsistencies up to (but not
580 including) there being no parent indicated NS resource record
581 referencing a server that is able to serve the child zone. This
582 robustness is one quality that has fueled the success of the DNS.
583 Still, the inconsistency is an error state and steps need to be taken
584 to make it apparent (if it is unplanned) and to make it clear once
585 the inconsistency has been removed.
587 Another issue is that the AXFR server could be authoritative for a
588 different set of zones than the AXFR client. It is possible that the
589 AXFR server be authoritative for both halves of an inconsistent cut
590 point and that the AXFR client is authoritative for just the parent of
593 The question that arises is, when facing a situation in which a cut
594 point's NS resource records do not match the authoritative set, whether
595 an AXFR server responds with the NS resource record set that is in the
596 zone being transferred or is at the authoritative location.
598 The AXFR response MUST contain the cut point NS resource record set
599 registered with the zone whether it agrees with the authoritative set
600 or not. "Registered with" can be widely interpreted to include data
601 residing in the zone file of the zone for the particular serial
602 number (in zone file environments) or as any data configured to be in
603 the zone (database), statically or dynamically.
605 The reasons for this requirement are:
607 1) The AXFR server might not be able to determine that there is an
608 inconsistency given local data, hence requiring consistency would mean
609 a lot more needed work and even network retrieval of data. An
610 authoritative server ought not be required to perform any queries.
612 2) By transferring the inconsistent NS resource records from a server
613 that is authoritative for both the cut point and the apex to a client
614 that is not authoritative for both, the error is exposed. For example,
615 an authorized administrator can manually request the AXFR and inspect
616 the results to see the inconsistent records. (A server authoritative
617 for both halves would otherwise always answer from the more
618 authoritative set, concealing the error.)
620 3) The inconsistent NS resource record set might indicate a problem
621 in a registration database.
623 4) This requirement is necessary to ensure that retrieving a given
624 (zone,serial) pair by AXFR yields the exact same set of resource
625 records no matter which of the zone's authoritative servers is
626 chosen as the source of the transfer.
628 If an AXFR server were allowed to respond with the authoritative
629 NS RRset of a child zone instead of a glue NS RRset in the zone
630 being transferred, the set of records returned could vary depending
631 on whether or not the server happens to also be authoritative for
634 The property that a given (zone,serial) pair corresponds to a
635 single, well-defined set of records is necessary for the correct
636 operation of incremental transfer protocols such as IXFR
637 [RFC1995]. For example, a client may retrieve a zone by AXFR from
638 one server, and then apply an incremental change obtained by IXFR
639 from a different server. If the two servers have different ideas
640 of the zone contents, the client can end up attempting to
641 incrementally add records that already exist or to delete records
646 As quoted in the previous section, section 4.2.1 of RFC 1034 provides
647 guidance and rationale for the inclusion of glue records as part of
648 an AXFR transfer. And, as also argued in the previous section of this
649 document, even when there is an inconsistency between the address in a
650 glue record and the authoritative copy of the name server's address,
651 the glue resource record that is registered as part of the zone for
652 that serial number is to be included.
654 This applies to glue records for any address family [RFC1700].
656 The AXFR response MUST contain the appropriate glue records as
657 registered with the zone. The interpretation of "registered with"
658 in the previous section applies here. Inconsistent glue records are
659 an operational matter.
663 Compression of names in DNS messages is described in RFC 1035, section
664 4.1.4, "Message compression". The issue highlighted here relates to a
665 comment made in RFC 1034, section 3.1, "Name space specifications and
666 terminology" which says "When you receive a domain name or label, you
667 should preserve its case." ("Should" in the quote predates [BCP14].)
669 Name compression in an AXFR message MUST preserve the case of the
670 original domain name. That is, although when comparing a domain name,
671 "a" equals "A", when comparing for the purposes of message compression,
672 "a" is not equal to "A". Note that this is not the usual definition
673 of name comparison in the DNS protocol and represents a new
674 requirement on AXFR servers.
676 Rules governing name compression of RDATA in an AXFR message MUST
677 abide by the specification in "Handling of Unknown DNS Resource Record
678 (RR) Types" [RFC3597], specifically, section 4 on "Domain Name
683 Dynamic Update [RFC2136] operations, and in particular its interaction
684 with DNAME [RFC2672], can have a side effect of occluding names in a
685 zone. The addition of a delegation point via dynamic update will
686 render all subordinate domain names to be in a limbo, still part of
687 the zone but not available to the lookup process. The addition of a
688 DNAME resource record has the same impact. The subordinate names are
689 said to be "occluded."
691 Occluded names MUST be included in AXFR responses. An AXFR client MUST
692 be able to identify and handle occluded names. The rationale for this
693 action is based on a speedy recovery if the dynamic update operation
694 was in error and is to be undone.
698 AXFR sessions are currently restricted to TCP by section 4.3.5 of RFC
699 1034 that states: "Because accuracy is essential, TCP or some other
700 reliable protocol must be used for AXFR requests." The restriction to
701 TCP is also mentioned in section 6.1.3.2. of "Requirements for Internet
702 Hosts - Application and Support" [RFC1123].
704 The most common scenario is for an AXFR client to open a TCP connection
705 to the AXFR server, send an AXFR query, receive the AXFR response, and
706 then close the connection. There are variations on this, such as a
707 query for the zone's SOA resource record first, and so on. Note that
708 this is documented as a most common scenario.
710 The assumption that a TCP connection is dedicated to the single AXFR
711 session is incorrect, this has led to implementation choices that
712 prevent either multiple concurrent zone transfers or the use of the
713 open connection for other queries.
715 Being able to have multiple concurrent zone transfers is considered
716 desirable by operators who have sets of name servers that are
717 authoritative for a common set of zones. It would be desirable
718 if the name server implementations did not have to wait for one
719 zone to transfer before the next could begin. The desire here is to
720 tighten the specification, not a change, but adding words to the
721 unclear areas, to define what is needed to permit two servers to
722 share a TCP connection among concurrent AXFR sessions. The challenge
723 is to design this in a way that can fall back to the old behavior if
724 either the AXFR client or AXFR server is incapable of performing
725 multiple concurrent AXFR sessions.
727 With the addition of EDNS0 and applications which require many
728 small zones such as in web hosting and some ENUM scenarios, AXFR
729 sessions on UDP would now be possible and seem desirable. However,
730 there are still some aspects of the AXFR session that are not easily
731 translated to UDP. This document leaves AXFR over UDP undefined.
735 In the original definition there is an implicit assumption (probably
736 unintentional) that a TCP connection is used for one and only one
737 AXFR session. This is evidenced in no requirement to copy neither
738 the Query Section nor the message ID in responses, no explicit
739 ordering information within the AXFR response messages and the lack
740 of an explicit notice indicating that a zone transfer continues in the
743 The guidance given here is intended to enable better performance of
744 the AXFR exchange as well as guidelines on interactions with older
745 software. Better performance includes being able to multiplex DNS
746 message exchanges including zone transfer sessions. Guidelines for
747 interacting with older software are generally applicable to new AXFR
748 clients. In the reverse situation, older AXFR client and newer AXFR
749 server ought to induce the server to operate within the specification
752 4.1.1 AXFR client TCP
754 An AXFR client MAY request a connection to an AXFR server for any
755 reason. An AXFR client SHOULD close the connection when there is
756 no apparent need to use the connection for some time period. The
757 AXFR server ought not have to maintain idle connections, the burden
758 of connection closure ought to be on the client. Apparent need for
759 the connection is a judgment for the AXFR client and the DNS
760 client. If the connection is used for multiple sessions, or if it is
761 known sessions will be coming or if there is other query/response
762 traffic anticipated or currently on the open connection, then there
765 An AXFR client MAY cancel delivery of a zone only by closing the
766 connection. However, this action will also cancel all other outstanding
767 activity using the connection. There is no other mechanism by which
768 an AXFR response can be cancelled.
770 When a TCP connection is closed remotely (relative to the client),
771 whether by the AXFR server or due to a network event, the AXFR client
772 MUST cancel all outstanding sessions and non-AXFR transactions.
773 Recovery from this situation is not straightforward. If the disruption
774 was a spurious event, attempting to restart the connection would be
775 proper. If the disruption was caused by a medium or long term
776 disruption, the AXFR client would be wise to not spend too many
777 resources trying to rebuild the connection. Finally, if the connection
778 was dropped because of a policy at the AXFR server (as can be the case
779 with older AXFR servers), the AXFR client would be wise to not retry
780 the connection. Unfortunately, knowing which of the three cases above
781 (momentary disruption, failure, policy) applies is not possible with
782 certainty, and can only be assessed by heuristics.
784 An AXFR client MAY use an already opened TCP connection to start an
785 AXFR session. Using an existing open connection is RECOMMENDED over
786 opening a new connection. (Non-AXFR session traffic can also use an
787 open connection.) If in doing so the AXFR client realizes that
788 the responses cannot be properly differentiated (lack of matching
789 query IDs for example) or the connection is terminated for a remote
790 reason, then the AXFR client SHOULD NOT attempt to reuse an open
791 connection with the specific AXFR server until the AXFR server is
792 updated (which is of course, not an event captured in the DNS
795 4.1.2 AXFR server TCP
797 An AXFR server MUST be able to handle multiple AXFR sessions on a
798 single TCP connection, as well as handle other query/response
801 If a TCP connection is closed remotely, the AXFR server MUST cancel
802 all AXFR sessions in place. No retry activity is necessary; that is
803 initiated by the AXFR client.
805 Local policy MAY dictate that a TCP connection is to be closed. Such
806 an action SHOULD be in reaction to limits such as those placed on
807 the number of outstanding open connections. Closing a connection in
808 response to a suspected security event SHOULD be done only in extreme
809 cases, when the server is certain the action is warranted. An
810 isolated request for a zone not on the AXFR server SHOULD receive
811 a response with the appropriate return code and not see the connection
816 AXFR sessions over UDP transport are not defined.
820 A zone administrator has the option to restrict AXFR access to a zone.
821 This was not envisioned in the original design of the DNS but has
822 emerged as a requirement as the DNS has evolved. Restrictions on AXFR
823 could be for various reasons including a desire (or in some instances,
824 having a legal requirement) to keep the bulk version of the zone
825 concealed or to prevent the servers from handling the load incurred in
826 serving AXFR. All reasons are arguable, but the fact remains that
827 there is a requirement to provide mechanisms to restrict AXFR.
829 A DNS implementation SHOULD provide means to restrict AXFR sessions to
832 An implementation SHOULD allow access to be granted to Internet
833 Protocol addresses and ranges, regardless of whether a source address
834 could be spoofed. Combining this with techniques such as Virtual
835 Private Networks (VPN) [RFC2764] or Virtual LANs has proven to be
838 A general purpose implementation is RECOMMENDED to implement access
839 controls based upon "Secret Key Transaction Authentication for DNS"
840 [RFC2845] and/or "DNS Request and Transaction Signatures ( SIG(0)s )"
843 A general purpose implementation SHOULD allow access to be open to
844 all AXFR requests. I.e., an operator ought to be able to allow any
845 AXFR query to be granted.
847 A general purpose implementation SHOULD NOT have a default policy
848 for AXFR requests to be "open to all." For example, a default could
849 be to restrict transfers to addresses selected by the DNS
850 administrator(s) for zones on the server.
854 An AXFR client MUST ensure that only a successfully transferred
855 copy of the zone data can be used to serve this zone. Previous
856 description and implementation practice have introduced a two-stage
857 model of the whole zone synchronization procedure: Upon a trigger
858 event (e.g., polling of SOA resource record detects change in the
859 SOA serial number, or via DNS NOTIFY [RFC1996]), the AXFR session
860 is initiated, whereby the zone data are saved in a zone file or
861 data base (this latter step is necessary anyway to ensure proper
862 restart of the server); upon successful completion of the AXFR
863 operation and some sanity checks, this data set is 'loaded' and
864 made available for serving the zone in an atomic operation, and
865 flagged 'valid' for use during the next restart of the DNS server;
866 if any error is detected, this data set MUST be deleted, and the
867 AXFR client MUST continue to serve the previous version of the zone,
868 if it did before. The externally visible behavior of an AXFR client
869 implementation MUST be equivalent to that of this two-stage model.
871 If a server rejects data contained in an AXFR session, the server
872 SHOULD remember the serial number and MAY attempt to retrieve the
873 same zone version again. The reason the same retrieval could make
874 sense is that the reason for the rejection could be rooted in an
875 implementation detail of one AXFR server used for the zone and not
876 in another AXFR server used for the zone.
878 Ensuring that an AXFR client does not accept a forged copy of a zone is
879 important to the security of a zone. If a zone operator has the
880 opportunity, protection can be afforded via dedicated links, physical
881 or virtual via a VPN among the authoritative servers. But there are
882 instances in which zone operators have no choice but to run AXFR
883 sessions over the global public Internet.
885 Besides best attempts at securing TCP connections, DNS implementations
886 SHOULD provide means to make use of "Secret Key Transaction
887 Authentication for DNS" [RFC2845] and/or "DNS Request and Transaction
888 Signatures ( SIG(0)s )" [RFC2931] to allow AXFR clients to verify the
889 contents. These techniques MAY also be used for authorization.
891 7 Backwards Compatibility
893 Describing backwards compatibility is difficult because of the lack of
894 specifics in the original definition. In this section some hints at
895 building in backwards compatibility are given, mostly repeated from the
898 Backwards compatibility is not necessary, but the greater the extent of
899 an implementation's compatibility the greater it's interoperability.
900 For turnkey implementations this is not usually a concern. For general
901 purpose implementations this takes on varying levels of importance
902 depending on the implementer's desire to maintain interoperability.
904 It is unfortunate that a need to fall back to older behavior cannot be
905 discovered, hence needs to be noted in a configuration file. An
906 implementation SHOULD, in it's documentation, encourage operators to
907 periodically review AXFR clients and servers it has made notes about as
908 old software periodically gets updated.
912 An AXFR server has the luxury of being able to react to an AXFR
913 client's abilities with the exception of knowing if the client can
914 accept multiple resource records per AXFR response message. The
915 knowledge that a client is so restricted apparently cannot be
916 discovered, hence it has to be set by configuration.
918 An implementation of an AXFR server MAY permit configuring, on a per
919 AXFR client basis, a need to revert to single resource record per
920 message; in that case, the default SHOULD be to use multiple records
924 An AXFR client has the opportunity to try other features (i.e., those
925 not defined by this document) when querying an AXFR server.
927 Attempting to issue multiple DNS queries over a TCP transport for an
928 AXFR session SHOULD be aborted if it interrupts the original request,
929 and SHOULD take into consideration whether the AXFR server intends to
930 close the connection immediately upon completion of the original
931 (connection-causing) zone transfer.
933 8 Security Considerations
935 Concerns regarding authorization, traffic flooding, and message
936 integrity are mentioned in "Authorization" (section 5), "TCP" (section
937 4.2) and "Zone Integrity" (section 6).
939 9 IANA Considerations
941 No new registries or new registrations are included in this document.
943 10 Internationalization Considerations
945 The AXFR protocol is transparent to the parts of DNS zone content that
946 can possibly be subject to Internationalization considerations.
947 It is assumed that for DNS labels and domain names, the issue has been
948 solved via "Internationalizing Domain Names in Applications (IDNA)"
954 Earlier editions of this document have been edited by Andreas
955 Gustafsson. In his latest version, this acknowledgement appeared.
957 "Many people have contributed input and commentary to earlier versions
958 of this document, including but not limited to Bob Halley, Dan
959 Bernstein, Eric A. Hall, Josh Littlefield, Kevin Darcy, Robert Elz,
960 Levon Esibov, Mark Andrews, Michael Patton, Peter Koch, Sam Trenholme,
961 and Brian Wellington."
963 Comments since the -05 version have come from these individuals:
964 Alfred Hoenes, Mark Andrews, Paul Vixie, Wouter Wijngaards, Iain
965 Calder, Tony Finch, Ian Jackson, Andreas Gustafsson, Brian Wellington,
966 and other participants of the DNSEXT working group.
970 All references prefixed by "RFC" can be obtained from the RFC Editor
971 web site at the URLs: http://rfc-editor.org/rfc.html
972 or http://rfc-editor.org/rfcsearch.html ;
973 information regarding this organization can be found at the following
974 URL: http://rfc-editor.org/
978 [RFC0793] Postel, J., "Transmission Control Protocol", STD 7, RFC 793,
980 [RFC0768] Postel, J., "User Datagram Protocol", STD 6, RFC 768, August
982 [RFC1034] Mockapetris, P., "Domain names - concepts and facilities",
983 STD 13, RFC 1034, November 1987.
984 [RFC1035] Mockapetris, P., "Domain names - implementation and
985 specification", STD 13, RFC 1035, November 1987.
986 [RFC1123] Braden, R., "Requirements for Internet Hosts - Application
987 and Support", STD 3, RFC 1123, October 1989.
988 [RFC1995] Ohta, M., "Incremental Zone Transfer in DNS", RFC 1995,
990 [RFC1996] Vixie, P., "A Mechanism for Prompt Notification of Zone
991 Changes (DNS NOTIFY)", RFC 1996, August 1996.
992 [RFC2136] Vixie, P., Ed., Thomson, S., Rekhter, Y., and J. Bound,
993 "Dynamic Updates in the Domain Name System (DNS UPDATE)", RFC
995 [RFC2181] Elz, R. and R. Bush, "Clarifications to the DNS
996 Specification", RFC 2181, July 1997.
997 [RFC2671] Vixie, P., "Extension Mechanisms for DNS (EDNS0)", RFC 2671,
999 [RFC2672] Crawford, M., "Non-Terminal DNS Name Redirection", RFC 2672,
1001 [RFC2845] Vixie, P., Gudmundsson, O., Eastlake 3rd, D., and B.
1002 Wellington, "Secret Key Transaction Authentication for DNS
1003 (TSIG)", RFC 2845, May 2000.
1004 [RFC5395] Eastlake 3rd, "Domain Name System (DNS) IANA Considerations",
1005 BCP 42, RFC 5395, November 2008.
1006 [RFC2930] Eastlake 3rd, D., "Secret Key Establishment for DNS (TKEY
1007 RR)", RFC 2930, September 2000.
1008 [RFC2931] Eastlake 3rd, D., "DNS Request and Transaction Signatures
1009 ( SIG(0)s )", RFC 2931, September 2000.
1010 [RFC3425] Lawrence, D., "Obsoleting IQUERY", RFC 3425, November 2002.
1011 [RFC3597] Gustafsson, A., "Handling of Unknown DNS Resource Record
1012 (RR) Types", RFC 3597, September 2003.
1013 [RFC4033] Arends, R., Austein, R., Larson, M., Massey, D., and S.
1014 Rose, "DNS Security Introduction and Requirements", RFC 4033,
1016 [RFC4034] Arends, R., Austein, R., Larson, M., Massey, D., and S.
1017 Rose, "Resource Records for the DNS Security Extensions",
1018 RFC 4034, March 2005.
1019 [RFC4509] Hardaker, W., "Use of SHA-256 in DNSSEC Delegation Signer
1020 (DS) Resource Records (RRs)", RFC 4509, May 2006
1021 [RFC5155] Laurie, B., Sisson, G., Arends, R., and D. Blacka, "DNS
1022 Security (DNSSEC) Hashed Authenticated Denial of Existence",
1023 RFC 5155, March 2008
1024 [RFC4035] Arends, R., Austein, R., Larson, M., Massey, D., and S.
1025 Rose, "Protocol Modifications for the DNS Security
1026 Extensions", RFC 4035, March 2005.
1027 [RFC4635] Eastlake 3rd, D., "HMAC SHA (Hashed Message Authentication
1028 Code, Secure Hash Algorithm) TSIG Algorithm Identifiers",
1029 RFC 4635, August 2006.
1030 [DNSFLGS] http://www.iana.org/assignments/dns-header-flags
1031 [DNSVALS] http://www.iana.org/assignments/dns-parameters
1035 [BCP14] Bradner, S., "Key words for use in RFCs to Indicate
1036 Requirement Levels", BCP 14, RFC 2119, March 1997.
1037 [RFC1700] J. Reynolds and J. Postel, "Assigned Numbers", RFC 1700,
1039 [RFC2764] Gleeson, B., Lin, A., Heinanen, J., Armitage, G., and A.
1040 Malis, "A Framework for IP Based Virtual Private Networks",
1041 RFC 2764, February 2000.
1042 [RFC3490] Faltstrom, P., Hoffman, P., and A. Costello,
1043 "Internationalizing Domain Names in Applications (IDNA)", RFC
1045 [DRAFT1] Jansen, J., "Use of SHA-2 algorithms with RSA in DNSKEY and
1046 RRSIG Resource Records for DNSSEC",
1047 draft-ietf-dnsext-dnssec-rsasha256-12, work in progress.
1048 [DRAFT2] Weiler, S., and D. Blacka, "Clarifications and Implementation
1049 Notes for DNSSECbis",
1050 draft-ietf-dnsext-dnssec-bis-updates-08, work in progress.
1055 46000 Center Oak Plaza
1056 Sterling, VA, 22033, US
1058 ed.lewis@neustar.biz