Skip to content

Repository files navigation

🐚 Web Reverse Shell Generator

React Vite Tailwind CSS License: MIT GitHub Pages

A modern, browser-based shell payload generator built with React, Vite, and Tailwind CSS. Supports Reverse Shells, Bind Shells, and MSFVenom command generation β€” all from the browser. This is the web port of the Python Reverse Shell Generator desktop application, designed for penetration testers, red teamers, and CTF players.


App Screenshot


🌐 Live Demo

πŸ‘‰ https://Ilias1988.github.io/ReverseShell-Web


✨ Features

Feature Description
🎨 Dark Mode UI Sleek, professional dark theme optimized for long hacking sessions
πŸ”€ 3 Mode Tabs Reverse Shell, Bind Shell, and MSFVenom generator in one tool
πŸ“š 170 Options 111 audited reverse/bind payloads plus 59 MSFVenom payload options
🐚 Shell Selector Choose shell binary (sh, bash, zsh, dash, ash, ksh, cmd.exe, powershell.exe, etc.)
πŸ’€ MSFVenom Generator Full command builder with payloads, formats, encoders, arch, platform, bad chars
✨ Smart Payload Advisor Rank payloads by transport, family, and binaries known to exist on the target
πŸ“– Payload Explanation Explain direction, requirements, placeholders, compatibility notes, and the guided workflow
πŸ§ͺ Catalog Confidence Every selectable payload is marked conditional or experimental; the UI never claims runtime verification without evidence
🏷️ Category Filter Filter payloads by language (Bash, Python, PHP, Java, PowerShell, C#, etc.)
⚑ Real-Time Generation Payload and listener update instantly as you type IP/Port
πŸ” Smart Encoding Supports Base64, URL Encode, and Double URL Encode
πŸ” Searchable Dropdown Quickly filter through payloads with live search
πŸ“‹ One-Click Copy Copy listener or payload to clipboard with animated feedback
πŸ“Š Payload Stats Line count and character count displayed in real-time
🏷️ Info Badges Active mode, shell, payload name, and encoding shown as badges
πŸ–₯️ Fullscreen Mode Press F11 for distraction-free fullscreen view
πŸ“± Responsive Works on desktop, tablet, and mobile devices
πŸ”” Toast Notifications Animated "Copied!" notifications
πŸ›‘οΈ Input Validation Validates hosts, ports, MSFVenom options, bad characters, and output filenames
βœ… Automated Verification Lint, unit tests, production build, prerender, and desktop/mobile browser checks
πŸš€ GitHub Pages Ready One-command deployment to GitHub Pages

βœ… Recent Reliability, Security & UX Improvements

The latest maintenance pass focused on making the application reliable in production, safer when building commands, and easier to use across devices.

Area Changes
Production rendering Fixed the prerender/React mounting conflict that could leave tabs, buttons, and inputs unresponsive after a production build
Mobile layout Fixed collapsed settings/output panels and restored normal page scrolling; the generated-payload panel now keeps a usable minimum height
PowerShell payloads Fixed {ip} and {port} substitution inside UTF-16LE PowerShell -EncodedCommand payloads before re-encoding
MSFVenom generator Added editable LHOST/RHOST and LPORT controls, automatic valid payload selection, format/platform/architecture/encoder compatibility checks, and safer argument quoting
Payload catalog Removed invalid webshell-style generator entries from selectable command payloads and corrected duplicate/incorrect MSFVenom entries
Catalog hardening Added a catalog-wide audit for unresolved placeholders, duplicate templates, metadata validity, and Advisor capability coverage
Generated source Fixed legacy doubled-brace output that could make generated C, C#, Go, and PowerShell source invalid
Docker runtime matrix Added isolated end-to-end Linux reverse/bind checks plus C and Node.js syntax validation; fixed a Ruby file-descriptor bug and a nested-brace normalization bug found by the matrix
MSFVenom compatibility matrix Validated every catalog payload, output format, and encoder against pinned Metasploit Framework 6.4.0; added representative cross-platform generation and handler checks
PowerShell compatibility matrix Added exact parser checks for seven direct templates plus safe outbound and bind-capability probes on Windows PowerShell 5.1; exact shell execution remains lab-only and is not claimed as verified
Offline reliability Removed runtime Google Fonts requests; the production UI now uses local system font stacks without a third-party network dependency
MSFVenom handlers Staged command shells and all Meterpreter payloads now generate exploit/multi/handler; Netcat is reserved for simple stageless command shells
Advisor accuracy Capabilities are derived from the real payload requirements, unavailable entries are hidden by default, and experimental entries require an explicit filter
Catalog scope Removed duplicate or delivery-only entries that depended on an unspecified hosted file; retained advanced entries with visible requirements and warnings
Shell selection Shell overrides are applied only to compatible templates; fixed payloads now display their actual required interpreter instead of a misleading disabled selection
Validation & safety Added host, port, integer-range, bad-character, and output-filename validation; invalid values no longer produce commands
Accessibility Added labels, ARIA tab/listbox semantics, pressed/expanded states, keyboard handling, and clearer validation feedback
React lifecycle Cleaned up timers and event listeners and removed state-sync effects that could cause stale selections or unnecessary renders
Prerender hardening Bound the temporary server to 127.0.0.1, added path confinement and malformed-URL handling, randomized its port, and guaranteed browser/server cleanup
Browser compatibility Build scripts can use Puppeteer's browser or automatically fall back to an installed Chrome, Edge, or Chromium executable
Toolchain security Upgraded Vite, Puppeteer, PostCSS, Tailwind CSS, and related build dependencies; npm audit reports 0 known vulnerabilities

Verification result

The repaired production build has been checked with:

  • ESLint with zero errors or warnings
  • 28/28 passing unit tests
  • Passing audit of all 111 selectable reverse/bind payloads
  • 23/23 passing isolated Linux Docker checks: 19 end-to-end sessions and 4 compiler/parser checks
  • 20/20 passing network-isolated MSFVenom checks: catalog, formats, encoders, 13 generation cases, and 4 handler configurations
  • 9/9 passing native PowerShell compatibility checks: 7 exact parser checks and 2 safe loopback capability probes
  • Successful Vite production build and static prerender
  • Successful desktop interaction test for MSFVenom LHOST updates
  • Successful mobile layout/scrolling test at a 390 Γ— 844 viewport
  • No browser runtime errors during the final end-to-end run

Catalog confidence levels

  • Verified β€” executed successfully in a recorded test environment. The catalog currently contains 19 Linux entries verified on the pinned Debian Docker matrix.
  • Conditional β€” the template, placeholders, and requirements passed static review, but behavior still depends on the target OS, binary implementation, version, firewall, and network path.
  • Experimental β€” uncommon, compiled, external-resource, or LOLBAS-style payload. Hidden by default in the Advisor and intended for deliberate lab validation.
  • Deprecated β€” retained only for compatibility and not recommended. There are currently no selectable deprecated entries.

The generator creates commands; it does not execute them. Always verify the generated output and listener in an isolated, authorized target before relying on it during an assessment.


πŸ”€ Mode Tabs

πŸ”™ Reverse Shell

The attacker listens and the target connects back. Classic reverse shell payloads for Linux and Windows.

πŸ”— Bind Shell

The target listens on a port and the attacker connects to the target. Useful when the target can't initiate outbound connections.

πŸ’€ MSFVenom

Full MSFVenom command generator with:

  • 59 payloads across Linux, Windows, macOS, Web (PHP/Java/Python), and Android
  • Staged & Stageless payload types
  • 45 output formats validated against the pinned compatibility baseline
  • 15 encoders (shikata_ga_nai, xor_dynamic, xor, and more)
  • Architecture selection (x86, x64, ARM, MIPS)
  • Platform selection
  • Bad characters, NOP sled, iterations, output file
  • Auto-generated listener/handler commands (nc or msfconsole)

🐚 Shell Selector

Dynamically swap the shell binary used in every payload:

Linux Shells Windows Shells
/bin/sh cmd.exe
/bin/bash powershell.exe
/bin/zsh pwsh.exe
/bin/ash
/bin/dash
/bin/ksh
/bin/csh
/bin/tcsh
/bin/mksh
/bin/bsh
sh (no path)
bash (no path)

How it works: When the selected payload supports shell substitution, occurrences of /bin/sh, /bin/bash, or cmd.exe are safely replaced with your selection. The selector is disabled for payloads that require a specific interpreter or cannot be rewritten reliably.


🎯 Supported Payloads

Reverse Shell β€” Linux / Generic (55 payloads)

  • Bash: -i, 196, read line, 5, UDP
  • Netcat: mkfifo, -e, -c, BusyBox
  • Ncat: TCP and UDP variants
  • Python: Python 2 & 3 variants, shortest one-liner
  • PHP: PentestMonkey, Ivan Sincek, system(), shell_exec(), popen(), and proc_open() variants
  • Languages: Perl, Ruby, Java, Node.js, Lua, Golang, Awk, Dart, Crystal, Haskell, Vlang
  • Tools: Socat (with TTY), OpenSSL, Telnet, zsh, sqlite3, and rustcat

Reverse Shell β€” Windows (24 payloads)

  • PowerShell: Multiple direct and Base64/EncodedCommand variants
  • Executables: nc.exe, ncat.exe
  • Living off the Land: MSBuild (experimental; requires an explicit build workflow)
  • Advanced: ConPtyShell (experimental; downloads a reviewed external script)
  • Languages: Python, Ruby, Perl, Lua, Golang, Java, Node.js, Groovy, Haskell

Bind Shell β€” Linux (18 payloads)

  • Netcat: nc, BusyBox nc, ncat (with --allow)
  • Socat: TCP + TTY variants
  • Languages: Python 2/3, Perl, PHP, Ruby, Node.js, Lua, Golang, Awk
  • Compiled: C bind shell

Bind Shell β€” Windows (14 payloads)

  • Executables: nc.exe, ncat.exe (with --allow)
  • PowerShell: 2 variants including hidden
  • Languages: Python, Ruby, Perl, PHP, Node.js, Lua, Golang
  • Compiled: C# bind shell

MSFVenom (59 payload options)

  • Linux: x86/x64 shell & meterpreter (staged + stageless)
  • Windows: x86/x64 shell & meterpreter (staged + stageless, HTTP/HTTPS)
  • macOS: x64 shell & meterpreter
  • Web: PHP, Java (JSP), Python meterpreter
  • Android: Meterpreter (TCP, HTTP, HTTPS)

πŸ“¦ Installation & Setup

Prerequisites

  • Node.js ^20.19.0 or >=22.12.0
  • npm (comes with Node.js)

Quick Start

# Clone the repository
git clone https://github.com/Ilias1988/ReverseShell-Web.git

# Navigate to the project directory
cd web-revshell

# Install dependencies
npm install

# Start development server
npm run dev

The app will open at http://localhost:3000.

Build for Production

npm run build

The optimized build will be in the dist/ directory.


πŸ§ͺ Testing & Verification

# Static analysis
npm run lint

# Core payload-generation and validation tests
npm test

# Full selectable-payload catalog audit
npm run audit:catalog

# Complete check: lint + tests + production build + prerender + browser E2E
npm run verify

# Complete check plus the isolated Linux Docker runtime matrix
npm run verify:runtime:linux

# Run only the pinned, network-isolated MSFVenom compatibility matrix
npm run test:runtime:msfvenom

# Native Windows PowerShell parser and safe loopback capability checks
npm run test:runtime:powershell

# Production verification plus the safe PowerShell compatibility matrix
npm run verify:runtime:powershell

# Complete check plus both Linux and MSFVenom Docker matrices
npm run verify:runtime

npm run verify uses a headless browser to confirm that the production build remains interactive on desktop and that the generated-payload panel is visible and scrollable on mobile.

Isolated Linux runtime matrix

npm run test:runtime:linux builds a local test image from the pinned official debian:bookworm-slim@sha256:abd67ffcfa541b485a3dff59865ab629aa048a6c613e639d36e7456b0b229241 base. Test containers run as an unprivileged user with all Linux capabilities dropped, no-new-privileges, resource limits, and --network none. Reverse and bind sessions communicate only through 127.0.0.1 inside each container.

The matrix executes Bash, GNU Awk, Netcat/Ncat, Python, Perl, PHP, Ruby, and Socat TCP/UDP entries end-to-end. C reverse/bind sources are checked with GCC, and Node.js reverse/bind sources are parsed with node --check. A syntax-only result is not promoted to runtime-verified status.

Isolated MSFVenom compatibility matrix

npm run test:runtime:msfvenom uses the pinned official Metasploit Framework 6.4.0 image at metasploitframework/metasploit-framework@sha256:ba9ecc0172052ea687adb3b3e6356b24dba4497d1bf73a6de0e201f1e25e9777. The container has no network access, uses a read-only root filesystem and a temporary /tmp, and is constrained by CPU, memory, and process limits. The test commands also run with no-new-privileges. The legacy image cannot start with every Linux capability dropped, so that stronger restriction is not claimed here. No generated payload is ever executed.

The matrix checks all 59 catalog payload names, all 45 output formats, and all 15 encoders against the pinned framework. It also generates 13 representative Linux, Windows, macOS, PHP, Java, Python, and Android artifacts, and loads four handler configurations without starting a listener. Docker Hub reports roughly 715 MB of downloadable image content; Docker Desktop reports about 3.03 GB once unpacked locally. This is a reproducible compatibility baseline, not a claim that every later Metasploit release has identical names or formats.

Native PowerShell compatibility matrix

npm run test:runtime:powershell runs on native Windows PowerShell 5.1. It parses the five direct reverse templates and two bind templates exactly as they are rendered, including the UTF-16LE Base64 variant. It also performs a harmless outbound data transfer over 127.0.0.1 and verifies that a loopback-only TcpListener can start and stop. No downloaded resource or remote command is executed by the default matrix.

On the recorded Windows PowerShell 5.1.26100.9168 / Windows NT 10.0.26200.0 host, an explicit attempt to execute the complete reverse template was blocked by the enabled Defender/AMSI controls with ScriptContainedMaliciousContent. Those protections were not disabled or bypassed. Consequently, the exact PowerShell shells remain conditional; the 9/9 compatibility result is not an end-to-end runtime-verification claim.

For a dedicated, owner-controlled Windows lab VM, the optional npm run test:runtime:powershell:lab command enables the six exact loopback shell handshakes. It should not be used on a normal workstation, and a security control block is a valid environmental result rather than something the harness tries to evade.


πŸš€ Deploy to GitHub Pages

# Build and deploy in one command
npm run deploy

This will build the project and push the dist/ folder to the gh-pages branch.


πŸ–ΌοΈ How to Use

Reverse / Bind Shell

  1. Select a mode β€” Click Reverse, Bind, or MSFVenom tab
  2. Enter your IP address (LHOST/RHOST) in the IP field
  3. Enter your listening port (LPORT) in the Port field
  4. Select the target OS β€” Linux or Windows
  5. Choose a shell β€” Pick from sh, bash, zsh, dash, cmd.exe, powershell.exe, etc.
  6. Filter by category (optional) β€” Click a language tag (Bash, Python, PHP, etc.)
  7. Choose a payload from the searchable dropdown (type to filter!)
  8. Select encoding (optional): None, Base64, URL, or Double URL
  9. Copy the Listener/Connect command β€” click Copy
  10. Copy the Payload β€” click Copy Payload

Smart Payload Advisor

  1. Choose Reverse or Bind and the target operating system
  2. Click Smart Payload Advisor above the payload filters
  3. Select TCP/UDP and an optional payload family
  4. Mark only binaries or interpreters you know are available on the target
  5. Review the Capability match, Check requirements, and Unavailable explanations
  6. Click Use payload to apply a recommendation without changing the IP, port, encoding, or OS

Leaving all target capabilities unselected keeps every matching payload visible and marks its requirements as unconfirmed. By default, the Advisor recommends reviewed conditional entries and hides experimental entries. Use the Catalog confidence filter only when you intentionally want to inspect advanced payloads.

Payload Explanation

  1. Select any reverse or bind payload
  2. Click Explain selected payload
  3. Review connection direction, interpreter, required binaries, and placeholders
  4. Check compatibility warnings before using the command in an authorized lab
  5. Follow the listener/payload workflow and optional Linux TTY-stabilization notes

Explanations are generated entirely from trusted local metadata and never execute or upload a payload.

MSFVenom Generator

  1. Switch to the MSFVenom tab
  2. Select Platform (Linux, Windows, macOS, Web, Android)
  3. Select Type (Staged or Stageless)
  4. Choose a Payload from the dropdown
  5. Select Output Format (exe, elf, raw, python, c, csharp, etc.)
  6. Configure Encoder, Iterations, Bad Characters, NOP sled
  7. Set Architecture and Platform (or leave auto-detect)
  8. Optionally set an Output File name
  9. Copy the generated msfvenom command and listener/handler

πŸ’‘ Tip: All fields update in real-time. Change the IP/Port and watch the output update instantly!


⌨️ Keyboard Shortcuts

Key Action
F11 Toggle Fullscreen Mode
Escape Exit Fullscreen Mode

πŸ“ Project Structure

web-revshell/
β”œβ”€β”€ eslint.config.js                    # ESLint configuration
β”œβ”€β”€ index.html                          # HTML entry point
β”œβ”€β”€ package.json                        # Dependencies & scripts
β”œβ”€β”€ vite.config.js                      # Vite configuration
β”œβ”€β”€ tailwind.config.js                  # Tailwind CSS configuration
β”œβ”€β”€ postcss.config.js                   # PostCSS configuration
β”œβ”€β”€ scripts/
β”‚   β”œβ”€β”€ browser.js                      # Installed-browser discovery for Puppeteer
β”‚   β”œβ”€β”€ prerender.js                    # Hardened static prerender workflow
β”‚   β”œβ”€β”€ runtime-test-linux.js           # Isolated Linux runtime matrix
β”‚   β”œβ”€β”€ runtime-test-msfvenom.js        # Pinned Metasploit compatibility matrix
β”‚   β”œβ”€β”€ runtime-test-powershell.js      # Native PowerShell compatibility/lab matrix
β”‚   └── verify-build.js                 # Desktop/mobile production browser checks
β”œβ”€β”€ tests/
β”‚   └── core.test.js                    # Payload, metadata, Advisor, validation, MSFVenom, and PowerShell tests
β”œβ”€β”€ public/
β”‚   └── favicon.svg                     # App favicon
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ main.jsx                        # React entry point
β”‚   β”œβ”€β”€ App.jsx                         # Main app layout + mode tabs
β”‚   β”œβ”€β”€ index.css                       # Tailwind imports + custom styles
β”‚   β”œβ”€β”€ features/
β”‚   β”‚   β”œβ”€β”€ payloadAdvisor/
β”‚   β”‚       β”œβ”€β”€ advisorEngine.js        # Deterministic compatibility scoring and ranking
β”‚   β”‚       β”œβ”€β”€ payloadMetadata.js      # Validated metadata for all selectable payloads
β”‚   β”‚       └── PayloadAdvisor.jsx      # Accessible guided-selection dialog
β”‚   β”‚   └── payloadExplanation/
β”‚   β”‚       β”œβ”€β”€ explanationEngine.js    # Structured local payload explanations
β”‚   β”‚       └── PayloadExplanation.jsx  # Accessible explanation and workflow dialog
β”‚   β”œβ”€β”€ data/
β”‚   β”‚   β”œβ”€β”€ payloadsLinux.js            # 55 Linux reverse shell payloads
β”‚   β”‚   β”œβ”€β”€ payloadsWindows.js          # 24 Windows reverse shell payloads
β”‚   β”‚   β”œβ”€β”€ payloadsBindLinux.js        # 18 Linux bind shell payloads
β”‚   β”‚   β”œβ”€β”€ payloadsBindWindows.js      # 14 Windows bind shell payloads
β”‚   β”‚   β”œβ”€β”€ shells.js                   # Shell binary options (sh, bash, zsh, etc.)
β”‚   β”‚   └── msfvenomData.js            # MSFVenom payloads, formats, encoders, generator
β”‚   β”œβ”€β”€ utils/
β”‚   β”‚   β”œβ”€β”€ encoding.js                 # Encoding and PowerShell placeholder injection
β”‚   β”‚   β”œβ”€β”€ shells.js                   # Safe shell-override compatibility logic
β”‚   β”‚   └── validation.js               # Host, port, option, and filename validation
β”‚   β”œβ”€β”€ hooks/
β”‚   β”‚   └── useRevShell.js              # Core logic (state, generation, encoding, shell, categories)
β”‚   └── components/
β”‚       β”œβ”€β”€ layout/
β”‚       β”‚   β”œβ”€β”€ Header.jsx              # App header with GitHub link
β”‚       β”‚   └── Footer.jsx              # Status bar + credits
β”‚       β”œβ”€β”€ panels/
β”‚       β”‚   β”œβ”€β”€ SettingsPanel.jsx        # Left panel (IP, Port, OS, Shell, Category, Payload, Encoding)
β”‚       β”‚   β”œβ”€β”€ OutputPanel.jsx          # Right panel (Listener + Payload output + badges)
β”‚       β”‚   └── MsfvenomPanel.jsx       # MSFVenom generator (settings + output)
β”‚       └── ui/
β”‚           β”œβ”€β”€ CopyButton.jsx           # Animated copy-to-clipboard button
β”‚           └── Toast.jsx                # Success notification toast
└── README.md

πŸ› οΈ Adding Custom Payloads

You can easily extend the tool by adding your own payloads:

Reverse Shell Payloads

Edit src/data/payloadsLinux.js or src/data/payloadsWindows.js:

const LINUX_PAYLOADS = {
  // ... existing payloads ...
  "My Custom Shell": `my_command {ip} {port}`,
};

Bind Shell Payloads

Edit src/data/payloadsBindLinux.js or src/data/payloadsBindWindows.js:

const BIND_LINUX_PAYLOADS = {
  // ... existing payloads ...
  "My Bind Shell": `my_command -l {port}`,
};

Note: Use {ip} and {port} as placeholders β€” they will be automatically replaced with user input. Shell binaries (/bin/sh, cmd.exe) will be dynamically replaced based on the Shell Selector.

Every new selectable payload must also pass npm run audit:catalog. Add explicit metadata overrides when automatic category, runtime, transport, warning, or confidence inference would be misleading.

πŸ”Ž Compatibility references


πŸ”§ Tech Stack

Technology Purpose
React 18 UI framework
Vite 8 Build tool & dev server
Tailwind CSS 3 Utility-first CSS framework
Lucide React Beautiful SVG icons
gh-pages GitHub Pages deployment

πŸ”„ Comparison: Python vs Web Version

Feature Python (Desktop) Web (Browser)
Reverse Shell Payloads 90+ 90+
Bind Shell Payloads ❌ βœ… 32
MSFVenom Generator ❌ βœ… 59 payloads
Shell Selector ❌ βœ… 15 shells
Category Filter ❌ βœ…
Mode Tabs (Reverse/Bind/MSFVenom) ❌ βœ…
Real-time generation βœ… βœ…
Encoding (Base64, URL, Double URL) βœ… βœ…
Copy to clipboard βœ… βœ…
Fullscreen mode βœ… βœ…
Search/Filter payloads ❌ βœ…
Responsive design ❌ βœ…
Toast notifications ❌ βœ…
Payload stats (lines/chars) ❌ βœ…
Info badges ❌ βœ…
No installation required ❌ βœ…
Works on any device ❌ βœ…

⚠️ Legal Disclaimer

THIS TOOL IS PROVIDED FOR EDUCATIONAL PURPOSES AND AUTHORIZED SECURITY AUDITS ONLY.

By using this software, you agree that:

1. You will only use this tool on systems you own or have explicit written 
   permission to test.

2. You understand that unauthorized access to computer systems is illegal 
   and punishable by law.

3. The author(s) of this tool are NOT responsible for any misuse, damage, 
   or illegal activities conducted with this software.

4. You will comply with all applicable local, state, national, and 
   international laws and regulations.

USE AT YOUR OWN RISK. ALWAYS OBTAIN PROPER AUTHORIZATION BEFORE TESTING.

πŸ“„ License

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


🀝 Contributing

Contributions are welcome! Feel free to:

  • πŸ› Report bugs
  • πŸ’‘ Suggest new features
  • πŸ”§ Add new payloads (reverse, bind, or MSFVenom)
  • πŸ“ Improve documentation

πŸ™ Acknowledgments


Made with ❀️ for penetration testers

About

Advanced Web Reverse Shell Generator 🐚. Generate Reverse, Bind, and MSFVenom payloads instantly in your browser. Built with React, Vite & Tailwind for Pentesters & CTF players.

Topics

Resources

Stars

6 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages