Tor and SSH

As of version, Tor supports making its connections through a SOCKS 4 or 5 server. Some SSH clients can set up a SOCKS listener to perform dynamic port forwarding. This means that you might be able to get Tor to connect through your shell account, which could be useful if your ISP blocks Tor traffic in some way.


  • Tor >=
  • A shell account that supports port forwarding.
  • A SSH client that supports dynamic port forwarding through a SOCKS listener.

Note: Some shell providers may disable port forwarding.

Note: You will need a secure browser to use with Tor to prevent Fingerprinting and attacks. See TorifyHOWTO/WebBrowsers for instructions how Tor Browser can be used separately with custom proxy settings, without the bundled Tor/Vidalia.

Using OpenSSH

The OpenSSH client available on most Unix systems supports dynamic port forwarding with the -D switch.

This command will place SSH in the background while it listens for SOCKS requests on port 1080.

$ ssh -fN -D 1080

Using PuTTY on Windows

To make PuTTY open a SOCKS listener on port 1080, do the following:

{{attachment:putty.jpg|PuTTY configuration}}

Leave the destination address field blank, and select dynamic.

Configuring Tor

Edit your Tor configuration file and add the following:

Socks4Proxy localhost:1080

Then start Tor, and hope for the best.

Last modified 4 years ago Last modified on Dec 26, 2012, 7:00:52 PM