Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.bytejmp.com/llms.txt

Use this file to discover all available pages before exploring further.

Install

apt install sshuttle
pip install sshuttle
Requires Python on pivot host. No setup needed on pivot — uses SSH.

Basic Usage

Route all traffic to subnet through pivot.
sshuttle -r user@PIVOT_IP 10.10.10.0/24

With Key

sshuttle -r user@PIVOT_IP 10.10.10.0/24 --ssh-cmd "ssh -i /path/to/key"

With Password (sshpass)

sshpass -p 'password' sshuttle -r user@PIVOT_IP 10.10.10.0/24

Multiple Subnets

sshuttle -r user@PIVOT_IP 10.10.10.0/24 172.16.0.0/16

Route All Traffic

sshuttle -r user@PIVOT_IP 0.0.0.0/0

Exclude Subnets

sshuttle -r user@PIVOT_IP 10.10.10.0/24 -x 10.10.10.1/32

DNS Forwarding

sshuttle --dns -r user@PIVOT_IP 10.10.10.0/24

Non-Standard SSH Port

sshuttle -r user@PIVOT_IP:2222 10.10.10.0/24

Verbose / Debug

sshuttle -vvr user@PIVOT_IP 10.10.10.0/24

Advantages Over SSH SOCKS

  • No ProxyChains needed — transparent routing
  • Works with any tool (nmap TCP, curl, etc.)
  • DNS forwarding support
  • No SOCKS configuration per tool

Limitations

  • Requires Python on pivot
  • TCP only (no UDP/ICMP)
  • Needs root on attacker (iptables)

Quick Reference

TaskCommand
Route subnetsshuttle -r user@PIVOT 10.10.10.0/24
All trafficsshuttle -r user@PIVOT 0.0.0.0/0
With DNSsshuttle --dns -r user@PIVOT 10.10.10.0/24
With keysshuttle -r user@PIVOT SUBNET --ssh-cmd "ssh -i key"