Tuesday, February 12, 2008

Secure Wireless Proxy

After reading a Lifehacker post a while back on more secure wireless browsing, I decided to setup an SSH Tunnel + SOCKS Proxy for Firefox, including (optionally) using FoxyProxy to make things easier.

The short of it is:
  • Use "ssh -D 9999 user@server" to establish a connection to a remote server.
  • Use FoxyProxy to point to a SOCKS proxy on localhost.
The long of it is that the "-D" option causes ssh to setup a proxy server on your local box that redirects your browser requests to the remote box, then from the remote box out to the 'net. All of your wireless http transmissions will be encrypted and hence unreadable by sneaky folks in the airport (or Panera's, or Starbucks, or wherever), and your browsing will be as secure as if you were sitting on the remote box. (Not that that's secure by default, but it's at least not being broadcast all over your surroundings.)

Using FoxyProxy in this case simply makes it easier to switch back and forth between proxied and direct connections if you need to. FoxyProxy sits on the bottom toolbar in Firefox, and with a couple of clicks will let you switch between proxy setups (including a "no proxy" setup, if desired).