summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortgroman <>2017-06-26 09:25:08 -0700
committertgroman <>2017-06-26 09:25:08 -0700
commitea3643b0e993e510a3088912dbb4dff81ad46dd1 (patch)
tree0eea2ae47bb9b39344bab4bf44f83ae1bd8c5fbd
parent3a4fa507bc2f36dfbf943e803b54f0c0b915f467 (diff)
downloadchkdns-ea3643b0e993e510a3088912dbb4dff81ad46dd1.tar
chkdns-ea3643b0e993e510a3088912dbb4dff81ad46dd1.tar.gz
chkdns-ea3643b0e993e510a3088912dbb4dff81ad46dd1.tar.lz
chkdns-ea3643b0e993e510a3088912dbb4dff81ad46dd1.tar.xz
chkdns-ea3643b0e993e510a3088912dbb4dff81ad46dd1.zip
added chkdns.sh
-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