summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xchkdns.sh32
1 files changed, 32 insertions, 0 deletions
diff --git a/chkdns.sh b/chkdns.sh
new file mode 100755
index 0000000..0b6973d
--- /dev/null
+++ b/chkdns.sh
@@ -0,0 +1,32 @@
+#!/bin/bash
+
+#start definefine nameservers
+
+NS1=dns1.yourdomain.com
+NS2=dns2.yourdomain.com
+NS3=dns1.yourlegacydomain.com
+NS4=dns2.yourlegacydomain.com
+
+function findNameServer {
+ whois $currentdn | grep 'Name\ Server' | sed 's/^ *//' | sort -u
+}
+
+
+
+
+cat domains.lst | sort | uniq | while IFS= read -r currentdn ; do
+ currentns=$(findNameServer)
+
+
+ if `echo ${currentns} | grep -E "{$NS1|$NS2|$NS3|$NS4}" 1>/dev/null 2>&1`
+ then
+ #echo "DEBUG: FOUND"
+ echo "$currentdn"
+ else
+ echo "DEBUG: NOT Found" >/dev/null
+ fi
+
+ #echo $currentdn
+ #echo $currentns
+
+done