Date: Fri, 7 Apr 2006 10:36:32 -0400 From: Bill Moran <wmoran@collaborativefusion.com> To: hal <hal@cc.usu.edu> Cc: freebsd-questions@FreeBSD.ORG Subject: Re: Choosing which interface to use Message-ID: <20060407103632.4096d389.wmoran@collaborativefusion.com> In-Reply-To: <FC11C925-4213-47AA-B004-B6925305FC31@cc.usu.edu> References: <FC11C925-4213-47AA-B004-B6925305FC31@cc.usu.edu>
next in thread | previous in thread | raw e-mail | index | archive | help
hal <hal@cc.usu.edu> wrote: > I am setting up a VPN client on a 6.0 box of mine. > As a result of the VPN client (openvpn) running I > have two interfaces active, xl0 needed by the dhcp > client and tun0 used by the vpn client. > > The question. How do I tell an application perhaps telnet, > ssh, or ftp to use tun0 and not xl0? Ideally you would set up appropriate routes when you establish the VPN tunnel, and the kernel would know the correct direction based on the destination IP address. Since this isn't the case, I strongly suggest that you look into cleaning up your IP ranges so it can be. Never allow half-baked routing to exist, it just causes more and more headaches the longer you let it go. However, many programs have an option to control where the source port originates from. If the application you want to use supports this, you can specifiy the IP of your end of the VPN tunnel and it should force the traffic to go through the tunnel. ssh, for example uses -b to set the originating IP. I'll reiterate, however, that the _best_ way is to properly organize your routing so it happes automagically. -- Bill Moran Potential Technologies http://www.potentialtech.com
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060407103632.4096d389.wmoran>