Domain2IP: High-Speed Batch DNS Resolver for Security Researchers / 高性能批量域名解析工兵
🔍 The Need for Speed / 速度即正义
Whether you are a Red Teamer mapping an attack surface, or an SRE verifying DNS migration for thousands of domains, sequential nslookup is too slow.
无论你是绘制攻击面的红队人员,还是验证数千个域名 DNS 迁移的 SRE,传统的串行 nslookup 都太慢了。
Domain2IP is a specialized Python tool built for parallel bulk resolution.
⚡ Key Features / 核心特性
- Parallel Workers: Uses
ThreadPoolExecutorto resolve domains concurrently. Default: 10 threads, adjustable to 100+.
并行线程:使用ThreadPoolExecutor并发解析。默认 10 线程,可调整至 100+。 - Detailed Reporting: Separates successful resolutions from failures.
- Clean Output: Generates pure IP lists for easy piping into other tools (like Nmap or Zmap).
纯净输出:生成纯 IP 列表,便于管道传输给其他工具(如 Nmap 或 Zmap)。
🏃 Usage / 使用指南
Basic Run
Prepare domains.txt and run:
python domain_resolver.py -i domains.txt -o results.txt |
High-Performance Mode (50 Workers)
python domain_resolver.py -i domains.txt -w 50 --verbose |
🔗 Pipeline Integration
Combine with nmap for instant scanning:
# Resolve domains -> Filter IPs -> Scan with Nmap |
🔬 Performance Testing
On a standard M1 MacBook Air, resolving 10,000 domains:
- Sequential: ~45 minutes
- Domain2IP (50 workers): ~45 seconds
Stop waiting for DNS.
别再等 DNS 了。
本博客所有文章除特别声明外,均采用 CC BY-NC-SA 4.0 许可协议。转载请注明来源 HExLL-迷雾日志!