This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
if [ "$#" -eq 0 ]; | |
then | |
echo "pass host to scan" | |
exit 1 | |
fi | |
server=$1 | |
mxserver=`dig mx $server +short 2>/dev/null | tail -1 | cut -d ' ' -f2` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import xmltodict | |
from socket import inet_ntoa | |
from struct import pack | |
import sys | |
import urllib | |
def calcDottedNetmask(mask): | |
bits = 0xffffffff ^ (1 << 32 - mask) - 1 |