Guest User

Untitled

a guest
Jan 30th, 2022
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.92 KB | None | 0 0
  1. #button1["text"] = "Custom"
  2. #button2["text"] = "Custom"
  3. #button2["command"] = ""
  4. #button1["command"] = ""
  5.  
  6. import tkinter as tk
  7. import tkinter.font as tkFont
  8. from tkinter import ttk
  9. import keyboard
  10. import time
  11.  
  12. ###############################################
  13.  
  14. def stage1right():
  15. button2["text"] = "Keyboard"
  16. button1["text"] = "PyAutoGUI"
  17. button2["command"] = autokeybright
  18. button1["command"] = autokeybleft
  19.  
  20. def stage1left():
  21. button1["text"] = "4 Chars"
  22. button2["text"] = "Custom"
  23. button2["command"] = forrangeright
  24. button1["command"] = forrangeleft
  25.  
  26.  
  27.  
  28. def forrangeright():
  29. entry1 = ttk.Entry(root, width=40)
  30. entry1.pack(padx=10, pady=10, side="bottom")
  31. confirmi_button = ttk.Button(root, text="Confirm", command=confirmichars)
  32. confirmi_button.pack(padx=10, side="bottom", fill="x")
  33.  
  34. def confirmichars():
  35. customichars = entry1.get()
  36. print(customichars)
  37.  
  38. def forrangeleft():
  39. button1["text"] = "5"
  40. button2["text"] = "5"
  41. root.update()
  42. time.sleep(1)
  43. button1["text"] = "4"
  44. button2["text"] = "4"
  45. root.update()
  46. time.sleep(1)
  47. button1["text"] = "3"
  48. button2["text"] = "3"
  49. root.update()
  50. time.sleep(1)
  51. button1["text"] = "2"
  52. button2["text"] = "2"
  53. root.update()
  54. time.sleep(1)
  55. button1["text"] = "1"
  56. button2["text"] = "1"
  57. root.update()
  58. time.sleep(1)
  59. button1["text"] = "0"
  60. button2["text"] = "0"
  61. root.update()
  62. time.sleep(1)
  63. button1["text"] = "Cracking..."
  64. button2["text"] = "Cracking..."
  65. root.update()
  66. for i in range(10000):
  67. keyboard.write(str(i))
  68. button1["text"] = "Done"
  69. button2["text"] = "Done"
  70.  
  71.  
  72. def autokeybright():
  73. button1["text"] = "STAGE2L"
  74. button2["text"] = "STAGE2R"
  75.  
  76.  
  77. def autokeybleft():
  78. button2["text"] = "Stage2R"
  79. button1["text"] = "Stage2L"
  80.  
  81. root = tk.Tk()
  82. def_font = tk.font.nametofont("TkDefaultFont")
  83. def_font.config(size=30)
  84. root.title("Brute Force")
  85. root.configure(bg="#999999")
  86. monitor_center_x = root.winfo_screenwidth() / 2 - 500
  87. monitor_center_y = root.winfo_screenheight() / 2 - 250
  88.  
  89. root.geometry("1000x500+%d+%d" % (monitor_center_x, monitor_center_y))
  90.  
  91. root.resizable(width=False, height=False)
  92.  
  93. quit_button = ttk.Button(root, text="Programm beenden", command=root.destroy, state=tk.NORMAL)
  94. quit_button.pack(padx=10, pady=10, side="bottom", fill="x")
  95.  
  96. button1 = ttk.Button(root, text="for i in range", compound="left", padding=10, command=stage1left)
  97. button1.pack(pady=30, padx=30, side="left", expand=True, fill="both")
  98.  
  99. button2 = ttk.Button(root, text="bruteforce", compound="left", padding=10, command=stage1right)
  100. button2.pack(pady=30, padx=30, side="right", expand=True, fill="both")
  101.  
  102. root.mainloop()
Advertisement
Add Comment
Please, Sign In to add comment