Bitzu

CPSA ยท Open source information gathering

DNS zone transfers (AXFR and IXFR)

AXFR and IXFR, why unrestricted transfers expose a network and how to restrict them.

Key points

  • A zone transfer copies a zone from a primary to a secondary server.
  • AXFR sends the whole zone over TCP, bracketed by the SOA record.
  • IXFR sends only the changes since the client's serial.
  • If a server allows anyone to request AXFR, an outsider gets every host name and address in the zone in one query.
  • The fix is to limit transfers to named secondaries, for example with BIND's allow-transfer.

Source: https://www.rfc-editor.org/rfc/rfc5936

Practice questions

Single choice

Which transport does an AXFR zone transfer use?

  1. UDP only
  2. ICMP
  3. TCP
  4. Either, chosen randomly
Show answer

Answer: C. TCP

AXFR is defined over TCP only, because a whole zone does not fit in a single UDP datagram and needs a reliable stream. Tools such as dig switch to TCP automatically.

Select all that apply

Which data does an unrestricted zone transfer typically expose?

  1. Every host name defined in the zone
  2. The IP addresses those names resolve to
  3. Mail and text records in the zone
  4. The private keys of the DNS server
  5. User account passwords
Show answer

Answer: A. Every host name defined in the zone, B. The IP addresses those names resolve to, C. Mail and text records in the zone

A full transfer lists every record in the zone: host names, their addresses and other types such as MX and TXT. It does not include server private keys or user passwords, which are not zone data.

True or false

True or false: AXFR requests are sent over UDP like ordinary DNS lookups.

Show answer

Answer: False

AXFR sessions over UDP are not defined; the request is made over TCP. Ordinary small lookups normally use UDP, which is why the statement is a trap.

Practice 8 questions on this topic in Bitzu

Short lessons, instant explanations and spaced review of what you get wrong. Free on iOS and Android.

Download on the App StoreGet it on Google Play

More CPSA topics in this module