Skip to content

Instantly share code, notes, and snippets.

@meatcar
Created March 21, 2016 23:25
Show Gist options
  • Select an option

  • Save meatcar/5b86ef4fefe1244e8d06 to your computer and use it in GitHub Desktop.

Select an option

Save meatcar/5b86ef4fefe1244e8d06 to your computer and use it in GitHub Desktop.

How to make a SOCKSv5 proxy with only SSH

Theory

The remote machine needs to ssh into a machine available to the internet to create a proxy.

What to run

ssh -t -R <port>:localhost:22 remote "ssh -C2TNv -D <proxy port> <local user>@localhost -p <port>"

Then, configure your application to use socks5://localhost:<proxy port> as it's proxy.

Enjoy!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment