#!/bin/bash

dns=ns1.colordns.de

while true 
do
 DOM="agserver.de agadmin.de andregeissler.de julianegeissler.de geisslermail.de reinsberg-frankfurt.de"
 RED='\033[0;31m'; NC='\033[0m'
 echo ""; echo ""; echo "";
 echo ""; echo ""; echo "";
 echo ""; echo ""; echo "";

 for I in $DOM
 do
  echo -n -e "$RED"
  echo -e "DOMAIN $I $NC"
  dig MX  $I @$dns | grep -C3 ';; ANSWER' | grep -v ';' | egrep -v "^$"
  dig NS  $I @$dns | grep -C3 ';; ANSWER' | grep -v ';' | egrep -v "^$"
  dig TXT $I @$dns | grep -C3 ';; ANSWER' | grep -v ';' | egrep -v "^$"
  dig TXT mail._domainkey.$I  @$dns | grep -C3 ';; ANSWER' | grep -v ';;' | grep -v ";mail" | egrep -v "^$" | egrep ".{50}"
  dig TXT _adsp._domainkey.$I @$dns | grep -C3 ';; ANSWER' | grep -v ';;' | grep -v ";_ads" | egrep -v "^$"
  echo ""
 done

 sleep 60
done
