Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

On Linux or Mac OS X how can I perform DNS lookups over an established SSH Tunnel?

How can I restrict DNS lookups of the form *.mydomain.com

Can I redirect all attempts to access domains of the form *.mydomain.com via the SSH tunnel?

I basically want to be able to SSH, RDP, and browse the web as if I was connected to the internal network. Standard VPN software I have is kind of buggy with my OS and with an SSH tunnel I have more control.

share|improve this question
up vote 1 down vote accepted

If you're just concerned about DNS while browsing, Firefox has a configuration setting for this:

network.proxy.socks_remote_dns

If you set the value to true, DNS calls will use your SOCKS proxy.

share|improve this answer

I wrote a long piece about doing this end to end from within a corporate network. The article contains masses of extra stuff which it sounds like you may not need, but I also touch on the DNS specific stuff.

Take a look here : http://godeater.cream.org/vpn.html

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .