LCD GUI for P4wnP1 ALOA

Overview

GUI for P4wnP1

  • Colorful UI interface for P4wnP1 ALOA
  • Don't pwn just as a USB client. Use also the USB host capabilities!
  • UPS Lite support
  • Scalability (I tried my best to make it easier to add new menus)

Main menu

I wanted to use also USB host capabilites of the P4wnP1.

So I implemented few scripts like Keystrokes->Duckyscript, Logitech dump with more scripts TODO; to make it more swissarmyknife like.

Device

Features

  • System info
  • Deploy HID attacks, templates
  • Gamepad
  • Dump logitech dongle (via munifying)
  • Automatically backdoor logitech dongle (if logitacker present)
  • Show images
  • Plug-in rubberducky/keyboard and get duckyscript!
  • Change UI colors

Typing speed Gamepad

Setup

Hardware

Layout

📝 Requirements:

🗡 For logitech attacks

🔨 Hardware tips

If you are planning to use the USB adapter you cannot solder it straight to the RPI.

You will need to place it under the UPS lite, because you will not be able to plug it in a laptop.

If you want smaller device you can shorten the pins on the raspberry pi. But I do not recommend it.

Instead solder new set of pins from bottom, with LCD placed on them.

Header fitment

🧾 Software

Download latest P4wnP1 aloa image on sdcard.

cd /root/
git clone https://github.com/gloglas/rpi_gui
sudo ./rpi_gui/setup.sh

If errors are not present just reboot your pi and you are set!

💾 Config gui_conf.json

It can be saved/loaded from options menu.

{
    "COLORS": {
        "BACKGROUND": "#000000",
        "BORDER": "#0e0e6b",
        "GAMEPAD": "#141494",
        "GAMEPAD_FILL": "#EEEEEE",
        "SELECTED_TEXT": "#EEEEEE",
        "SELECTED_TEXT_BACKGROUND": "#141494",
        "TEXT": "#9c9ccc"
    },
    "PATHS": {
        "ANALYZED_HID": "/root/rpi_gui/ducky/",
        "ANALYZED_HID_LOGS": "/root/rpi_gui/log/",
        "BASH_SCRIPTS": "/usr/local/P4wnP1/scripts/",
        "HID": "/usr/local/P4wnP1/HIDScripts/",
        "IMAGEBROWSER_START": "/root/",
        "MUNIFYING": "/root/munifying/"
    },
    "PINS": {
        "KEY1_PIN": 21,
        "KEY2_PIN": 20,
        "KEY3_PIN": 16,
        "KEY_DOWN_PIN": 19,
        "KEY_LEFT_PIN": 5,
        "KEY_PRESS_PIN": 13,
        "KEY_RIGHT_PIN": 26,
        "KEY_UP_PIN": 6
    }
}

💻 Making your own menu and functions

The menu class has its own structure. I'll try to explain it to you the best I can.

Menu

Key "a" is a definition for menu.

If you are in "ab" menu and go one menu back, it will go to the "a" menu.

Items and structure

The items in menu in menu are in array.

First value is text displayed to the user.

The second value is:

  • Menu which will be displayed next (specified by [a-z]) - "ab"
  • Function with own stuff - ShowInfo
  • Function with parameter - [Templates, "WIFI"] or [SetColor, 2]
menu = {
    "a": (
        ["System info", ShowInfo],
        ["HID", "ab"],
        ["Logitech attacks", "ac"],
        ["USB tools", "ad"],
        ["Template selector", "aa"],
        ["Other features","ag"],
        ["Options", "ae"],
        ["System", "af"]
    ),
    "aa": (
        ["Full settings", [Templates, "FULL_SETTINGS"]],
        ["WiFi", [Templates, "WIFI"]],
    ..snip..
    "aea": (
        ["Background", [SetColor, 0]],
        ["Text", [SetColor, 2]],
    ..snip..
}

So If you want to add your own you just follow the example.

Function called from menu

Requires:

  • It is recommended to set location (basically just user is not in menu) with - m.which = m.which + "1"
  • Draw empty background - color.DrawMenuBackground()
  • Wait a few milliseconds so the user doesn't accidentally presses some button - time.sleep(0.4)
  • After leaving the function, set the location accordingly with - m.which = m.which[:-1]
def ShowInfo():
    m.which = m.which + "1"
    color.DrawMenuBackground()
    time.sleep(0.4)
    
    # Your stuff here

    m.which = m.which[:-1]

👍 Helper functions

Dialogs

Yes or No dialog

YNDialog

def YNDialog(a="Are you sure?", y="Yes", n="No",b=""):

Arguments: First line; text for YES; text for NO; Second line; Returns: True/False

Dialog

def Dialog(a, wait=True):

Basic Message box

Arguments: Text; Waits for user to click ok;

Scroll trought text (like in menu)

def GetMenuString(inlist,duplicates=False):

Arguments: List of strings with labels to show; bool, if your lists contains duplicates (to show the list properly); Returns: Selected string from array.

Show text without selection ("slide")

def GetMenuPic(a):

Arguments: List of lists with labels to show; Returns: Index of selected slide (-1 for none).

Wait for button press

def getButton():

Returns: Name of the pressed button (defined in json config).

RGB color picker

Color picker

def GetColor(final_color="#000000"):

Arguments: Color you start with; Returns: #RRGGBBselected color in hex

📋 TODO

  • More features for Logitech stuff
  • Dump USB storage
  • Construct HID payloads
  • Terminal

📚 Credits and sources

Owner
John
He really loves hardware but he is sometimes lost when it comes to using a git.
John
Example GUI for Command line capable machine learning programs

Example GUI for Command line capable machine learning programs This is an example GUI made in PysimpleGUI and Tkinter, mainly for machine learning pro

Kim Yongwook 4 May 31, 2022
A GUI based CRUD database management system built using mysql and python

A GUI based CRUD database management system built using mysql and python

Aquila 2 Feb 13, 2022
PyEditor - A Simple Text Editor for python

PyEditor work in progress Text Editor for python Installation git clone https://github.com/ArmenG888/PyEditor Install the libraries Linux or mac pip

ArmenG 3 Mar 15, 2022
Signin/Signup GUI form using tkinter in python

SignIn-SignUpFormRepo Hello there, I am Shahid and this is the Signin/Signup GUI form using tkinter in python if you want to use avatar images then pa

Shahid Akhtar 1 Nov 09, 2021
A Python native, OS native GUI toolkit.

Toga A Python native, OS native GUI toolkit. Prerequisites Minimum requirements Toga requires Python 3. Python 2 is not supported. If you're on macOS,

BeeWare 3.3k Jan 02, 2023
A simple project used Tkinter module to make a seperate window

Project Title This is a program to run a databse where you can store the general information of poeple. This is a very simple project and i have used

Divyansh Bhardwaj 0 Jun 25, 2022
A GUI panel to manage multi monitor on i3wm.

Monitor manager Only for I3wm (Just for now) It's about two years that I'm using i3 as my window manager and in my experience this window manager allo

Wire.Nemo 3 Nov 06, 2021
Python code examples on how to create several applications using Dear PyGui.

Python code examples on how to create several applications using Dear PyGui. Includes building and editing a table, as well as visualizing sorting algorithms in a plot.

Alexander H. 7 Sep 15, 2022
This repository contains some projects that I have done using Python + Tkinter.

This repository contains some projects that I have done using Python + Tkinter.

João Victor Vilela dos Santos 1 Nov 10, 2021
A system tray application written in python that will assist you with your keyboard endeavors.

A system tray application written in python that will assist you with your keyboard endeavors. It has features such as abbreviation, email autofill, media control, writing from clipboard ,typing curr

Mach50 1 Dec 15, 2021
Make desktop applications using HTML and CSS with python

Neutron Make desktop applications using HTML and CSS with python What is Neutron Neutron will allow developers to design modern applications in python

Ian Baldelli 284 Dec 29, 2022
Aplicação GUI feita em Python para estudos de cadastro (forms).

Cadastro de DEVs GUI 💻 A ideia original veio do repositório do https://github.com/PedroTomazeti nomeado 'Projetos-Independentes-HTML-CSS' Nele há um

Yago Goltara 3 Aug 15, 2021
Pyint is the graphic software which is written in Python

Pyint About Pyint Pyint is the graphic software which is written in Python(I use the Turtle graphics). The name 'Pyint' is compound word of 'Python' a

John 1 Nov 06, 2021
TextTUI is a set of extensions to the Textual and Textual-Inputs libraries

TextTUI is a set of extensions to the Textual and Textual-Inputs libraries. Currently a Work in Progress that is based on the 0.1.14 branch of

3 Feb 10, 2022
Key Cast - Cast your key presses and mouse clicks on the screen, while casting your favorite application on the screen. Better than the rest.

Key Cast Screen cast your keyboard and mouse clicks in style Project Homepage » View Demo · Report Bug · Request Feature Table of Contents Introductio

Mehul Singh Teya 13 Dec 23, 2022
CBMPy Metadraft: a flexible and extensible genome-scale model reconstruction tool

CBMPy Metadraft: a flexible and extensible, GUI-based genome-scale model reconstruction tool that supports multiple Systems Biology standards.

Systems Biology Lab, Vrije Universiteit Amsterdam 1 Mar 14, 2022
Create custom desktop notificatons using python

Create custom desktop notificatons using python In this video i am going to use a module called plyer

Niranjan 2 Dec 15, 2021
Basic calculator using Tkinter GUI

Basic calculator using Tkinter GUI

Rogerio Penchel 17 Jan 09, 2022
A html canvas based screencasting server with occasional ground-truth updates via screenshots and very fast input drawing

rm2canvas A html canvas based screencasting server for the reMarkable 1/2 digital paper systems. It draws live on the canvas from the remarkables touc

45 Sep 08, 2022
MediaPlayer-with-PyQt5 - The Multimedia Player with Python and PyQt5

MediaPlayer-with-PyQt5 I made this Multimedia Player with Python and PyQt5, I re

4 Oct 06, 2022