Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm looking for a way to acomplish several things that have been bothering me. I access the Internet through many insecure (and often poorly maintained) networks, many of which active block anything except HTTP/HTTPs traffic.

  1. Keep my browsing traffic private (as far as the "open" network I'm on is concerned)
  2. I run a SVN server on port 8443, which is activly blocked at many locations, I'd like a way to tunnel through 443 to my home computer and then back to my SVN server on 8443.
  3. Setup other programs to use whatever "tunnel" I create for the above two

I'm thinking that something like SSH would be a good option, but I've never set it up and I'm not sure I can even route all my traffic through it.

share|improve this question

2 Answers 2

up vote 2 down vote accepted

I am more familiar with ssh than I am with OpenVPN or any VPN for that matter. My solution will attempt to use ssh to solve all your problems. A VPN could be a better solution though.

Using ssh, you'd have to set up a your home system to be a SSH server. I use Ubuntu in VirtualBox as my server. You may also be able to use OpenSSH for windows (but i would advise against it). You should also install something like denyhosts to block ip addresses that try to brute force your ssh password. It sounds like your going to want to set up your ssh server to host on port 442 instead of 22. You'll need to keep track of your home public IP address or use a service like DynDNS.

1 & 3. You can use your home ssh server as a SOCKS proxy server to make most or all of your outgoing traffic go through the encrypted ssh session. You can use putty on your remote system to connect to your home system and set up the SOCKS.

  • In putty, enter the host name or public IP address of your home system (at which it can be connected to from the internet). The port will be 443 if thats what you set it up to be on your home ssh server (and forwarded through the router).

  • Before you open the connection, scroll down to SSH -> Tunnels. Type in some large un-used port number in Source port (like 9000). Leave Destination blank. Select Dynamic. Then Open the connection.

Putty Config for SOCKS

  • Now in your web browser you'll have to set it up to use SOCKS. Set the host to localhost and the port to 9000. If you set these settings up in internet explorer, most other applications will use those settings to connect to the internet as well. You can set programs to use the proxy on an individual basis too (like Firefox).

IE config for SOCKS

2.To set up your remote system to be a SVN server through your home system, you can also use SSH and Putty. Your home system would however first have to be set up as if it were an SVN server by forwarding port 8443 through the router. Then from your remote system (the actual SVN server) ssh to your home system in putty using Source port 8443 and destination localhost:8443. I believe you'll need to check the two check boxes at the top too so that more than just your home system can use its local port 8443 as an SVN server. Its probably the same as the -g option in the ssh command line arguments.

enter image description here

share|improve this answer
    
Thats exactly what I needed! –  Nate Apr 20 '11 at 3:06
    
@Nate if you run into issues with the second part, you might have to change "localhost:8443" to the home IPaddress:8443 or "*:8443". You may also have to change settings on the ssh server to enable external connections to the forwarded port. You can find more details in the ssh_config man page (linux.die.net/man/5/ssh_config) with emphasis on "RemoteForward" and "GatewayPorts". –  James T Apr 21 '11 at 1:02
    
Actually, doing the first step allows me to get to the other sites as well. –  Nate Apr 21 '11 at 1:38
    
@Nate glad to hear it all works –  James T Apr 21 '11 at 2:12

Have you looked at LogMeIn Hamachi? It's a pretty simple but very secure and free private VPN tunnel service.

I have used it briefly but don't know if it supports port forwarding such as you're looking for.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.