
مُحلِّل سريع لتحويل عناوين IP إلى أسماء مضيفين مع PTR، والبحث عن SSL/TLS، وSNI، وJSON.
whathost هي أداة استطلاع عالية الأداء مصممة لمتخصصي الأمن، ومختبري الاختراق، وصائدي مكافآت الثغرات. تقوم بتحويل عناوين IP إلى أسماء مضيفين بسرعة عبر فحص شهادات SSL/TLS واستعلامات DNS PTR، مما يوفر تعدادًا شاملًا للمضيفين لتقييمات الأمن.
تعداد شهادات SSL/TLS
:8443، :8080)استعلامات DNS PTR
تحسين الأداء
مرونة الإخراج
الموثوقية
go install gitlab.com/bountrix/whathost@latest
git clone https://gitlab.com/bountrix/whathost.git
cd whathost
go build -o whathost
sudo mv whathost /usr/local/bin/whathost
whathost -version
فحص سريع من ملف:
whathost -i targets.txt
خط الأنابيب من stdin:
cat ips.txt | whathost
فحص عالي السرعة باستخدام 100 عامل:
whathost -i targets.txt -t 100
الوضع الصامت للحصول على مخرجات نظيفة:
whathost -i targets.txt -silent | sort -u
تعداد SSL فقط (تخطي DNS):
whathost -i targets.txt -skip-dns -t 200
DNS فقط مع مُحلِّل مخصص:
whathost -i targets.txt -skip-ssl -r 8.8.8.8 -p 53
إخراج JSON مع الإحصاءات:
whathost -i targets.txt -json -stats -dedupe > results.json
فحص محدود المعدل مع تأخير:
whathost -i targets.txt -delay 100ms -timeout 15
SNI مخصص للمضيفين الافتراضيين:
whathost -i targets.txt -sni example.com -insecure
تصحيح الأخطاء المطوّل:
whathost -i targets.txt -v -stats
سير عمل الاستطلاع الكامل:
cat targets.txt | whathost -t 100 -dedupe -timestamp -o results.txt -stats
| العلامة | الاسم المستعار | الوصف |
|---|---|---|
-i | ملف الإدخال الذي يحتوي على عناوين IP (الافتراضي: stdin) | |
-o | ملف الإخراج للنتائج (الافتراضي: stdout) | |
-json | إخراج النتائج بصيغة JSON | |
-silent | -s | الوضع الصامت - إخراج أسماء المضيفين فقط |
-timestamp | إضافة طوابع زمنية بصيغة RFC3339 إلى النتائج |
| العلامة | الاسم المستعار | الوصف |
|---|---|---|
-t | -threads | عدد العمال المتزامنين (الافتراضي: 32) |
-delay | التأخير بين الطلبات (مثل 100ms، 1s) | |
-timeout | مهلة عميل HTTP بالثواني (الافتراضي: 10) |
| العلامة | الاسم المستعار | الوصف |
|---|---|---|
-r | -resolver | عنوان IP لمُحلِّل DNS مخصص |
-p | منفذ مُحلِّل DNS (الافتراضي: 53) | |
-protocol | بروتوكول DNS: udp أو tcp (الافتراضي: udp) | |
-dns-timeout | مهلة بحث DNS بالثواني (الافتراضي: 5) | |
-skip-dns | تخطي عمليات بحث DNS PTR |
| العلامة | الوصف |
|---|---|
-sni | تجاوز اسم مضيف SNI لاتصالات SSL |
-insecure | تخطي التحقق من شهادة TLS (الافتراضي: true) |
-skip-ssl | تخطي فحوصات شهادة SSL |
| العلامة | الاسم المستعار | الوصف |
|---|---|---|
-dedupe | إزالة تكرار أسماء المضيفين في الإخراج | |
-stats | عرض إحصائيات مفصلة عند الانتهاء | |
-v | -verbose | إخراج مطوّل مع معلومات التصحيح |
-banner | عرض لافتة ASCII عند بدء التشغيل | |
-version | عرض معلومات الإصدار |
[SSL-SAN] 143.43.221.133 -> example.com
[SSL-CN] 143.43.221.133 -> example.org
[DNS-PTR] 143.43.221.133 -> host.example.com
[SSL-SAN] 143.43.221.133:8443 -> api.example.com
{
"type": "SSL-SAN",
"ip": "143.43.221.133",
"hostname": "example.com",
"source": "certificate"
}{
"type": "SSL-CN",
"ip": "143.43.221.133",
"hostname": "example.org",
"source": "certificate"
}{
"type": "DNS-PTR",
"ip": "143.43.221.133",
"hostname": "host.example.com",
"source": "dns"
}{
"type": "SSL-SAN",
"ip": "143.43.221.133",
"hostname": "api.example.com",
"port": "8443",
"source": "certificate"
}
example.com
example.org
host.example.com
api.example.com
╔════════════════════════════════════════════╗
║ Statistics Report ║
╠════════════════════════════════════════════╣
║ Total IPs processed: 250 ║
║ SSL hostnames found: 487 ║
║ DNS PTR records: 198 ║
║ Unique hostnames: 623 ║
║ Failed checks: 12 ║
║ Time elapsed: 45.3s ║
║ Processing rate: 5.52 IPs/s ║
╚════════════════════════════════════════════╝
cat ip-ranges.txt | whathost -silent -dedupe | httprobe
whathost -i scope-ips.txt -stats -o discovered-hosts.txt
whathost -i company-ips.txt -json -dedupe > asset-inventory.json
cat ct-log-ips.txt | whathost -skip-dns -t 200 -silent
whathost -i targets.txt -skip-ssl -r 1.1.1.1 -v
يقبل iptohost تنسيقات إدخال متنوعة:
# Plain IPs
192.168.1.1
10.0.0.1
# IPs with ports
192.168.1.1:8443
10.0.0.1:9000
# CIDR ranges (each IP should be on its own line)
192.168.1.1
192.168.1.2
192.168.1.3
# Comments (lines starting with #)
# Production servers
192.168.1.100
# Staging servers
192.168.1.200
# HTTP(S) URLs (protocol will be stripped)
https://192.168.1.1
http://10.0.0.1:8080
ادمجها مع subfinder وhttpx:
subfinder -d example.com -silent | httpx -silent | whathost -silent | sort -u
تمرير المخرجات إلى nuclei لفحص الثغرات:
cat targets.txt | whathost -silent -dedupe | nuclei -t cves/