I'm trying to setup a VM which should be able to utilize the VPN connection of my host. The VM is running Debian Lenny and the host is OS X SL. For the VPN connection I use Juniper Network Connect which creates a new virtual interface named 'jnc0' when connected.
The purpose of the VM is for software development, and ideally it needs to satisfy multiple scenarios:
- Online without VPN connection.
- Online with VPN connection.
I have mostly fulfilled the first two by having two network interfaces setup for my VM. One bridged with the Airport interface on my host, and one host-only used for basic access from the host to the guest ('vboxnet0'). The guest is able to access the internet through the bridged connection, while two-way communication between host and guest for ssh, webserver, etc., works over the host-only connection.
Since Network Connect sets up a new virtual interface for the VPN connection on the host, the bridged connection with the airport doesn't give the guest access to VPN. What I'd like to do, is to setup a new host-only network ('vboxnet1') and a route between the jnc0 and the vboxnet1 to give the guest access to VPN. What I don't know is if that's feasible or not.
I also welcome better solutions/suggestions on how to accomplish this.