Closed p4p1 closed 9 months ago
Started work on a PyWidget python API class that would allow you to create custom widgets inside of havoc.
#!/usr/bin/env python # -*- coding: utf-8 -*- # Made by papi # Created on: Di 10 Okt 2023 01:54:42 CEST # havoc.py # Description:
import havocui
win = havocui.Widget("main title")
def call_in_widget(): print("in here") win.close() def call_checkbox(): print("checked")
def combo_box(num): print(num)
def process_line(string): print(string)
win.addLabel("This is a popup dialodjsaklfjdslkajfdlakfjdkslafjdskalfjdsaklfjsa'f;sadf;saj;fsjaklf;dsaj;fssg") win.addCheckbox("check me!", call_checkbox) win.addButton("click me!", call_in_widget) win.addCombobox(combo_box, "test", "test1", "test2") win.addLineedit("placeholder ...", process_line)
def call_btn(): win.exec()
havocui.createtab("Widget testing", "open widget", call_btn)
## Screenshot: ![image](https://github.com/HavocFramework/Havoc/assets/19672114/ad3c257f-8f8d-42b2-9c3a-654af3ea8d5d)
I love this 😄
Started work on a PyWidget python API class that would allow you to create custom widgets inside of havoc.
added features:
Testing code:
import havocui
win = havocui.Widget("main title")
def call_in_widget(): print("in here") win.close() def call_checkbox(): print("checked")
def combo_box(num): print(num)
def process_line(string): print(string)
win.addLabel("This is a popup dialodjsaklfjdslkajfdlakfjdkslafjdskalfjdsaklfjsa'f;sadf;saj;fsjaklf;dsaj;fssg") win.addCheckbox("check me!", call_checkbox) win.addButton("click me!", call_in_widget) win.addCombobox(combo_box, "test", "test1", "test2") win.addLineedit("placeholder ...", process_line)
def call_btn(): win.exec()
havocui.createtab("Widget testing", "open widget", call_btn)