Felix Buenemann | 4 Dec 2006 21:39
Picon

Custom Routing Setup

Hello,

I'd like to ask what's the proper way to setup custom routes with vpnc.
I've seen some hints that this is possible in the manpage, but found no
further details. Also searches of the mailinglist via google didn't help
me much.

I'm using vpnc-3.3.3-r90 from svn on darwin 8.8.1 (MacOS X 10.4.8 Intel).

I have two vpn configurations:
- WLAN for connection at the university and to be able to access the
internet via proxy
- Dialin for connection from home

Currently both configs setup default route to the university network,
but I'd like the Dialin config to keep (eg. not override) the default
route of my LAN - so regular LAN/WWW traffic goes via my router - and
instead use a Network-Route to the IP-range used by university servers
(193.16.0.0/16).

I see some code for setting up routing in the vpnc-script, but it seems
to gather it's data from the connection negotiated with the vpn gateway,
so I'm not sure where to insert the routing configuration info.

Best Regards,
   Felix Buenemann
Eduard Bloch | 5 Dec 2006 10:07
Picon
Picon

Patch for custom routes

#include <hallo.h>
* Felix Buenemann [Mon, Dec 04 2006, 09:39:49PM]:
> Hello,
> 
> I'd like to ask what's the proper way to setup custom routes with vpnc.
> I've seen some hints that this is possible in the manpage, but found no
> further details. Also searches of the mailinglist via google didn't help
> me much.
> 
> I'm using vpnc-3.3.3-r90 from svn on darwin 8.8.1 (MacOS X 10.4.8 Intel).
> 
> I have two vpn configurations:
> - WLAN for connection at the university and to be able to access the
> internet via proxy
> - Dialin for connection from home

The Debian packages have some tweaks for such situation. Basicaly you
create different profile with different config files called
/etc/vpnc/profilename.conf, and you can specify custom routes therein,
in which case no automatic default route is set and yours are used.

See attachment.

Eduard.
 <at> DPATCH <at> 
diff -urNad vpnc~/config.c vpnc/config.c
--- vpnc~/config.c	2005-10-28 16:01:59.000000000 +0200
+++ vpnc/config.c	2005-11-02 09:03:07.000000000 +0100
(Continue reading)


Gmane