Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/github30/shell2udp
Executing shell commands via UDP server
https://github.com/github30/shell2udp
executor os-command-injection popen python shell shell2http shell2udp subprocess udp webhook
Last synced: 3 days ago
JSON representation
Executing shell commands via UDP server
- Host: GitHub
- URL: https://github.com/github30/shell2udp
- Owner: GitHub30
- License: mit
- Created: 2022-08-25T00:12:42.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2022-11-29T04:39:06.000Z (almost 2 years ago)
- Last Synced: 2024-09-25T16:37:00.808Z (about 1 month ago)
- Topics: executor, os-command-injection, popen, python, shell, shell2http, shell2udp, subprocess, udp, webhook
- Language: Python
- Homepage: https://pypi.org/project/shell2udp/
- Size: 19.5 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[![Python](https://img.shields.io/pypi/pyversions/shell2udp.svg)](https://badge.fury.io/py/shell2udp)
[![PyPI](https://badge.fury.io/py/shell2udp.svg)](https://badge.fury.io/py/shell2udp)# shell2udp
UDP-server to execute shell commands. Designed for development, prototyping or remote control. Settings through two command line arguments, path and shell command. By default bind to :8080.# Usage
```bash
shell2udp [options] ["shell command" for /] /path "shell command" /path2 "shell command2" ...
options:
-p, --port NNNN : port for udp server ( default 8080 )
```# Install
```bash
pip install shell2udp
```# Examples
## Windows
```powershell
shell2udp 'shutdown -s -t 0'
``````powershell
shell2udp 'shutdown -s -t 0' /beep "powershell -c echo `a"
``````powershell
shell2udp --port 3306 /beep 'powershell -command [Console]::Beep(440,2000)'
```### Dispatch
```powershell
[System.Net.Sockets.UdpClient]::New().Send("", 0, "localhost", 8080)
``````powershell
[System.Net.Sockets.UdpClient]::New().Send([System.Text.Encoding]::UTF8.GetBytes("/beep"), 5, "localhost", 8080)
# [System.Text.Encoding]::UTF8.GetBytes("/beep").Length
```## Linux
```bash
shell2udp 'notify-send Hello root'
``````bash
shell2udp -p3000 'notify-send Hello root' /path 'canberra-gtk-play -i desktop-login'
``````bash
shell2udp -p3000 /path 'canberra-gtk-play -i desktop-login'
```### Dispatch
```bash
echo > /dev/udp/localhost/8080
``````bash
echo /path > /dev/udp/localhost/8080
```# Acknowledgements
https://github.com/msoap/shell2http
https://github.com/eshaan7/Flask-Shell2HTTP