Awesome Open Source
Awesome Open Source


Python Versions PEP8 Contributors Issues License: GPL v3 Maintenance

rsh in action


rsh is a tool purely written in Python 3 to easily a generate reverse shell command for Linux as well as Windows.


This tools makes it easy for you to quickly generate reverse shell commands supported in both Linux and Windows, in the following languages:

  • bash
    • Bash reverse shell
    • netcat
    • netcat OpenBSD
    • nc.traditional
  • Python
    • IPv4
    • IPv6
  • Ruby
  • Perl
  • PHP
  • Powershell
  • Node.JS
  • Awk
  • Java


usage: rsh [-h] [-sh SH] [-listen] lhost lport

positional arguments:
  lhost       Specify local host ip
  lport       Specify a local port

optional arguments:
  -h, --help  show this help message and exit
  -sh SH      Specify the language to generate the reverse shell
  -listen     Spawn a netcat listener for this shell.

Using rsh is very simple. All you need to do is provide an IP and port and the type of shell that is to be generated:

  • ./rsh 4444 -sh bash
  • ./rsh 4444 -sh php
  • ./rsh 4444 -sh powershell

You can also automatically catch the reverse shell by starting a listener when you are done. This uses netcat and listens on the port you specified for your reverse shell

  • ./rsh 4444 -sh powershell -listen


You need to have Python 3.5 or greater installed to run rsh. Both Linux and Windows are supported. Along with that rsh uses pyfiglet which you can install by running:

pip install -r requirements.txt


  • Getting bash command

  • Options

  • Wrong IP 😄

  • Wrong PORT 😄


  • Report a bug
  • Fix something and open a pull request
  • Add more reverse shells

In any case feel free to open an issue


All the shell command are taken from pentestmonkey


This project is licensed under the GPLv3 License - see the LICENSE file for details


If you'd like you can buy me some coffee:

Buy Me A Coffee

Get A Weekly Email With Trending Projects For These Topics
No Spam. Unsubscribe easily at any time.
python (49,786
php (15,817
linux (2,268
windows (1,332
perl (1,229
powershell (1,228
bash (589
awk (46
reverse-shell (42
netcat (15

Find Open Source By Browsing 7,000 Topics Across 59 Categories