MCPcopy Create free account
hub / github.com/AutoRecon/AutoRecon / DNSZoneTransfer

Class DNSZoneTransfer

autorecon/default-plugins/dns-zone-transfer.py:3–18  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1from autorecon.plugins import ServiceScan
2
3class DNSZoneTransfer(ServiceScan):
4
5 def __init__(self):
6 super().__init__()
7 self.name = 'DNS Zone Transfer'
8 self.tags = ['default', 'safe', 'dns']
9
10 def configure(self):
11 self.match_service_name('^domain')
12
13 async def run(self, service):
14 if self.get_global('domain'):
15 await service.execute('dig AXFR -p {port} @{address} ' + self.get_global('domain'), outfile='{protocol}_{port}_dns_zone-transfer-domain.txt')
16 if service.target.type == 'hostname':
17 await service.execute('dig AXFR -p {port} @{address} {address}', outfile='{protocol}_{port}_dns_zone-transfer-hostname.txt')
18 await service.execute('dig AXFR -p {port} @{address}', outfile='{protocol}_{port}_dns_zone-transfer.txt')

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected