Skip to content

l2ol33rt/vpnc-split-tunnel

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

vpnc-split-tunnel

Overview

Basic script to be used inconjunction vpnc-scipt (comes with the installation of vpnc). This script also leverages dnsmasq to allow for you to define specific domains to query over the VPN connection while forwarding the rest of your dns queries to your local DNS. This allows for a truely transparent split tunnel experience.

Dependencies

  • vpnc
  • dnsmasq

Setup

  • Install the dependencies
  • Copy vpnc-split-tunnel.sh to /etc/vpnc/
  • Modify your existing vpnc.conf to reference vpnc-split-tunnel.sh using the "Script" variable
  • Start vpnc and verify the routes with netstat -rn

Configuration

Defaults

By default vpnc-split-tunnel.sh assumes the following:

  • The DNS server(s) are pushed from the VPN gateway
  • The domain(s) are pushed from the VPN gateway

If either or both of these assumptions are false you will need to modify some variables insidevpnc-split-tunnel.sh:

  • INTERNAL_IP4_DNS Set this variable to your DNS server IPs beyond the VPN gateway
  • CISCO_DEF_DOMAIN Set this variable to the domains of servers you would like to access by internal DNS

Additional Options

  • SUBNET_LIST Add a list of additional internal subnets to be accessible over the split tunnel.
  • RESOLV_CONF Locatin of resolv.conf
  • DNSMASQ_CONF Location of where to put the dnsmasq.conf that will be generated by this script
  • DNSMASQ_CONF_BACKUP Location of where to put the dnsmasq.conf backup file if a file exists before we generate the VPN specific config
  • DNSMASQ_LISTEN The IP the dnsmasq daemon will bind to
  • DNSMASQ_BIN dnsmasq binary

About

vpnc split tunnel script

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Languages