[ http://www.rootshell.com/ ]
From twiztah@ANARCHY.MAXHO.COM Mon Jul 6 08:56:13 1998
Date: Sun, 5 Jul 1998 23:36:35 -0400 (EDT)
From: twiztah <twiztah@ANARCHY.MAXHO.COM>
Subject: qpopscan.sh by twiztah
#qpopscan.sh by twiztah 7/5/98, enjoy script kidz.
#----[snip]-----------------------------------------
rm -rf qpscan 2>&1
ln -s `which telnet` qpscan
if test ! -r scanned.log; then
rm -rf scanned.log
touch scanned.log
fi
echo "+---------------------------------------------------+"
echo "| qpopscan.sh by twiztah [twiztah@maxho.com] 7/5/98 |"
echo "+---------------------------------------------------+"
if test -z $1; then
echo "uhm, i dont think you passed a parameter.."
echo "usage: "`basename $0`" yourdomain.com"
exit 0
fi
echo "scan("`grep -c scan scanned.log`"):" `date +"["%D" "%l:%M%p"]"` "-- $1" >> scanned.log
echo "[1] now scanning for subnets ($1)"
host -l $1 > $1.hostlist 2>&1
rm -rf subnet-do mailhosts 2>&1
cat $1.hostlist | grep "name server" | awk -F ' ' ' {print "host -l " $1 " >> mailhosts"}' >> subnet-do 2>&1
sort < subnet-do > subnet-do.sorted 2>&1
uniq < subnet-do.sorted > subnet-do.uniq 2>&1
rm -rf subnet-do subnet-do.sorted 2>&1
mv subnet-do.uniq subnet-do 2>&1
chmod 755 subnet-do 2>&1
rm -rf $1.hostlist 2>&1
echo "[2] now setting up the scan ($1)"
./subnet-do 2>&1
rm -rf subnet-do todo chk-qp 2>&1
cat mailhosts | grep "has address" | awk -F ' ' ' {print "./qpscan "$4" 110 >> chk-qp 2>&1 | (sleep 8 ; killall -9 qpscan > /dev/null 2>&1)"}' >> todo 2>&1
sort < todo > sorted.todo 2>&1
uniq < sorted.todo > uniqed.todo 2>&1
rm -rf todo sorted.todo 2>&1
mv uniqed.todo todo 2>&1
chmod 755 todo 2>&1
echo "[3] now scanning" `grep -c . todo` "machines for qpopper ($1)"
./todo > /dev/null 2>&1
rm -rf mailhosts todo 2>&1
echo "[4] done scanning ($1)"
echo ""
#we dont need the patched ones
cat chk-qp | grep -v 2.5 >> results.$1.stripped 2>&1
mv chk-qp results.$1.original 2>&1
echo "[!] QUALCOMM appeared : "`grep -ic QUALCOMM results.$1.stripped` "times"
echo "[!] QPOP appeared : "`grep -ic QPOP results.$1.stripped` "times"
echo "[*] original results : "results.$1.original
echo "[*] stripped results : "results.$1.stripped
echo "[%] this was scan num : "`grep -c scan scanned.log`
echo ""
echo "greets to: promo, joker, meta, retro, sinkhole, mj, icetrey and qualcomm"
echo "-[ftp://ftp.qualcomm.com/eudora/servers/unix/popper/qpopper2.52.tar.Z]-"
echo ""
#eof
#----[snap]-----------------------------------------
#i am not responsible for the use of this script
[twiztah@maxho.com] [07/05/98 11:35PM]
|