The ssh Tunnel of Love

   Print.Print
Email.Email weblog link
Blog this.Blog this
Edd Dumbill

Edd Dumbill
Jul. 23, 2001 01:25 PM
Permalink

Atom feed for this author. RSS 1.0 feed for this author. RSS 2.0 feed for this author.

I'm spending this week in San Diego, at O'Reilly's Open Source Convention. Not being the sort of person who can afford to leave work at home, there's plenty for me to do while I'm away. Happily, the hotel has ethernet Net access (not to mention the wireless Net access available in the conference.)

As I lead an unnecessarily complicated life while I'm away I need to get access to two separate networks: my home office, and a remote office of another company. My best friend when travelling like this is ssh (my wife, accompanying me, might disagree with this statement). By far the most common use of ssh is as a secure replacement for telnet, but when working remotely I find that setting up tunnels with ssh makes my life much easier.

From home, I want access to my IMAP server, which is safely behind my firewall. So I set up a ssh-tunnel to make my remote IMAP server appear in the right place on my Linux laptop, and have my mailer configured to look at mail on "localhost":

ssh -L 143:mailhost.org:143 edds-home-office.org

From the office, I need to look at a web server that runs on port 3000, so I set up a tunnel to make that web server appear on port 3000 on my local machine:

ssh -L 3000:mailhost:3000 remote-office.org

Easy -- so now I have resources from two remote firewalled networks appearing on my machine here, and both over secure connections. A year ago when travelling it was a bonus if I could even get a dial-up connection, now I can barely tell the difference from my office back in England. Apart from the glorious San Diego weather, that is.

Edd Dumbill is co-chair of the O'Reilly Open Source Convention. He is also chair of the XTech web technology conference. Edd conceived and developed Expectnation, a hosted service for organizing and producing conferences. Edd has also been Managing Editor for XML.com, a Debian developer, and GNOME contributor. He writes a blog called Behind the Times.