1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-07-04 05:55:23 +02:00
tldr/pages/common/sshuttle.md

22 lines
968 B
Markdown
Raw Normal View History

2017-12-14 20:36:25 +00:00
# sshuttle
> Transparent proxy server that tunnels traffic over an SSH connection.
2019-06-07 11:39:34 +01:00
> Doesn't require root or any special setup on the remote SSH server, though root access on the local machine is prompted for.
> More information: <https://manned.org/sshuttle>.
2017-12-14 20:36:25 +00:00
- Forward all IPv4 TCP traffic via a remote SSH server:
`sshuttle {{[-r|--remote]}} {{username}}@{{sshserver}} {{0.0.0.0/0}}`
2017-12-14 20:36:25 +00:00
2019-06-07 11:39:34 +01:00
- Also forward all DNS traffic to the server's default DNS resolver:
2017-12-14 20:36:25 +00:00
`sshuttle --dns {{[-r|--remote]}} {{username}}@{{sshserver}} {{0.0.0.0/0}}`
2017-12-14 20:36:25 +00:00
2019-06-07 11:39:34 +01:00
- Forward all traffic except that which is bound for a specific subnet:
`sshuttle {{[-r|--remote]}} {{username}}@{{sshserver}} {{0.0.0.0/0}} {{[-x|--exclude]}} {{192.168.0.1/24}}`
2019-06-07 11:39:34 +01:00
2017-12-19 12:07:35 +00:00
- Use the tproxy method to forward all IPv4 and IPv6 traffic:
2017-12-14 20:36:25 +00:00
`sshuttle --method tproxy {{[-r|--remote]}} {{username}}@{{sshserver}} {{0.0.0.0/0}} {{::/0}} {{[-x|--exclude]}} {{your_local_ip_address}} {{[-x|--exclude]}} {{ssh_server_ip_address}}`