A pure-Python reverse shell generator TUI for CTFs and pentesting.
Zero dependencies — stdlib only. Runs anywhere Python 3.8+ is installed.
- Based on https://www.revshells.com/ https://github.com/0dayCTF/reverse-shell-generator
- 40+ reverse shell payloads across Bash, Python, Netcat, PHP, Ruby, Perl, PowerShell, Java, Go, Node.js, Socat, Awk, Lua, and more
- MSFVenom quick-reference commands
- TTY upgrade one-liners
- Auto-detects IP from any network interface (default:
tun0) - One-keypress clipboard copy (
xclip,xsel, orpbcopy) - Persistent config at
~/.config/slopshell/config.toml - Handles tmux splits and terminal resizes cleanly
- No pip, no venv, no nonsense
# Interactive TUI
python3 slopshell.py
# Dump all shells to stdout (no TUI)
python3 slopshell.py --list <ip> <port>
# Example
python3 slopshell.py --list 10.10.14.5 4444| Key | Action |
|---|---|
↑ / ↓ |
Move up/down through the shell list |
PgUp / PgDn |
Jump a page at a time |
Home / End |
Jump to first/last shell |
Tab |
Cycle category forward |
Shift+Tab |
Cycle category backward |
Enter / y / c |
Copy selected shell to clipboard |
e |
Edit the LHOST IP address |
i |
Change the network interface (auto-resolves IP) |
p |
Edit the LPORT port number |
r |
Refresh IP from the configured interface |
s |
Save current IP, port, and category as defaults |
q |
Quit |
When an input prompt is open:
| Key | Action |
|---|---|
Enter |
Confirm value |
Esc |
Cancel — restores previous value |
Backspace |
Delete last character |
Ctrl+U |
Clear entire field |
Use Tab / Shift+Tab to filter shells by category:
| Category | Contents |
|---|---|
All |
Every shell |
Bash |
Bash TCP/UDP one-liners |
Python |
Python 2/3 variants |
Netcat |
nc, ncat, busybox nc |
PHP |
exec, shell_exec, proc_open, popen, passthru |
Ruby/Perl |
Ruby and Perl one-liners |
PowerShell |
PS one-liners, Base64, cmd.exe wrappers |
Other |
Java, Go, Awk, Lua, Socat, Node.js, curl |
MSFVenom |
msfvenom payload generation commands |
TTY Upgrade |
Python pty, stty, script, socat PTY pairs |
SLOPshell reads from ~/.config/slopshell/config.toml on startup.
Press s at any time to write the current session values to this file.
The file is created automatically on first save. You can also create it manually:
# ~/.config/slopshell/config.toml
default_port = "4444"
default_category = "All"
ip_from_interface = "tun0"
default_ip = ""| Key | Type | Default | Description |
|---|---|---|---|
default_port |
string | "4444" |
Port pre-filled on startup |
default_category |
string | "All" |
Category tab selected on startup. Must match exactly: All, Bash, Python, Netcat, PHP, Ruby/Perl, PowerShell, Other, MSFVenom, TTY Upgrade |
ip_from_interface |
string | "tun0" |
Network interface to read IP from at startup and on r refresh. Set to "" to disable and use default_ip instead |
default_ip |
string | "" |
Static IP used when ip_from_interface is empty or the interface cannot be found. Falls back to 10.10.14.X if both are unset |
Using an interface (default):
ip_from_interface = "tun0"
default_ip = ""SLOPshell reads the IPv4 address of tun0 on startup and when r is pressed.
Works for HTB (tun0), THM (tun0), or any other VPN interface (eth0, wlan0, etc).
Using a static IP:
ip_from_interface = ""
default_ip = "192.168.1.100"The IP is fixed at startup. Use e to change it mid-session, then s to persist.
Copy works automatically if any of these are installed:
xclip(X11)xsel(X11)pbcopy(macOS)
If none are available, the shell command is still displayed in the command box at the bottom of the screen for manual selection.
- Python 3.8+
- A terminal with at least 80×24 characters
- Linux or macOS (Windows not supported — no
fcntl)
tomllib (Python 3.11+ stdlib) is used to parse the config file. On Python 3.8–3.10 the config parser falls back to a simple built-in key=value reader that handles the generated format correctly.
- HTB / THM workflow: leave defaults as-is —
tun0is auto-detected on launch - After popping a shell: jump to
TTY Upgradecategory for stabilisation one-liners - Port reuse: press
p, change the port, presss— persisted for next time - tmux: works correctly across splits and pane switches; the layout redraws on resize
