DNS Zone Transfer Permitted
The DNS server allows a full zone transfer to any requester, handing over every record in the zone and with it a map of the organisation's hosts.
| Severity | Medium |
| CVSS 3.1 | 5.3 CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N Open in the calculator |
| CVSS 4.0 | 6.9 CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:N/VA:N/SC:N/SI:N/SA:N Open in the calculator |
| CWE | CWE-497: Exposure of Sensitive System Information to an Unauthorized Control Sphere |
| OWASP Top 10 | A01:2025 Broken Access Control |
| MITRE ATT&CK | T1590.002 DNS, T1018 Remote System Discovery |
| Category | Information Disclosure |
Description
The DNS server answers zone transfer requests (AXFR) from hosts that are not its secondary servers. Transfers exist so that secondary servers can copy a zone from the primary, and should be limited to those servers. A zone transfer returns every record in the zone at once: host names and addresses, mail and service records, aliases and text records.
An attacker therefore obtains a complete list of the zone's names and addresses in a single request, without the effort or noise of guessing names one by one. This reveals the organisation's hosts and their roles, including systems not linked from anywhere, such as test, development, remote access and management hosts, and on internal servers the layout of the internal network. The information gives no access by itself, but it makes reconnaissance faster and more complete, and points an attacker at the systems most likely to be weak. The exposure matters most on internal DNS servers, and on external servers whose zones mix public records with internal or development host names and private addresses.
The issue is confirmed by requesting a transfer of each zone from each of its name servers, for example with dig axfr or host -l, or with the Nmap dns-zone-transfer script. It is common for only one of several name servers to be misconfigured, so all of them should be tested.
Remediation
Allow zone transfers only to the zone's own secondary servers:
- On BIND, set
allow-transfer { none; };in theoptionsblock, as below, and in each primary zone that has secondaries, override it with anallow-transferstatement listing those servers' addresses or, better, a TSIG key they share with the primary. - On Windows DNS Server, on the Zone Transfers tab of each zone's properties, either clear Allow zone transfers or select Only to servers listed on the Name Servers tab or Only to the following servers. The same setting is available through the
SecureSecondariesparameter ofSet-DnsServerPrimaryZone. Active Directory-integrated zones replicate through Active Directory and often need no zone transfers at all. - For hosted DNS services and appliances, use the provider's setting to restrict or disable transfers.
- Keep internal host names and private addresses out of zones served to the internet, using separate internal and external zones.
Confirm the fix by requesting a transfer of every zone from every name server, from an address that is not a secondary, and checking that each request is refused.
References
Add This Finding to Your Library
In Pental this write-up is in Settings, Library. Add to my library copies it into your own, rated in your firm's CVSS version, ready to put in your own words.
Free trialYour trial starts when your portal goes live, not when you sign up, so the time you spend setting up does not count. · No card required
Only need the reporting? Our reporting tool is free and open source, with the same library.