|
|
|
@ -11,6 +11,8 @@ scan_ns=$2
|
|
|
|
|
# Static Configuration (Do not edit)
|
|
|
|
|
dns_time=5
|
|
|
|
|
dns_tries=1
|
|
|
|
|
#icmp_fail_text="$(tput bold)Tab Sorcery: $(tput setaf 1)ICMP connection to ${scan_ns} failed!$(tput sgr0)"
|
|
|
|
|
dns_fail_text="$(tput bold)Tab Sorcery: $(tput setaf 1)DNS connection to ${scan_ns} failed!$(tput sgr0)"
|
|
|
|
|
|
|
|
|
|
# Check for and set RDP geometry config
|
|
|
|
|
case "$SORC_GEOM_RDP" in
|
|
|
|
@ -30,7 +32,14 @@ get_hostip () {
|
|
|
|
|
host_ip=`echo $zone_xfer | grep $1 | grep A | awk '{print $3}'`
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
zone_xfer=`dig $scan_domain @$scan_ns +time=$dns_time +tries=$dns_tries AXFR | egrep -v 'SOA|NS|MX|DiG' | grep $scan_domain | awk '{print $1,$4,$5}'`
|
|
|
|
|
##Check network
|
|
|
|
|
#if ! ping -c1 -t3 $scan_ns >/dev/null 2>&1
|
|
|
|
|
#then
|
|
|
|
|
# echo $icmp_fail_text >&2
|
|
|
|
|
# return 1
|
|
|
|
|
#fi
|
|
|
|
|
|
|
|
|
|
zone_xfer=`{dig $scan_domain @$scan_ns +time=$dns_time +tries=$dns_tries AXFR || echo $dns_fail_text >&2} | egrep -v 'SOA|NS|MX|DiG' | grep $scan_domain | awk '{print $1,$4,$5}'`
|
|
|
|
|
while read host <&3; do
|
|
|
|
|
user_name=$3
|
|
|
|
|
connect_cmd="ssh -t"
|
|
|
|
|