Routing improvements (#268)

- Fixes #82 
- Remove `EXTRA_SUBNETS`
- Remove no longer needed iptables rules
- Reduce routing interface arity
- Routing setup is done in main.go instead of in the firewall
- Routing setup gets reverted at shutdown
This commit is contained in:
Quentin McGaw
2020-10-24 18:05:11 -04:00
committed by GitHub
parent 716eb14da1
commit ed4fcc17b3
15 changed files with 209 additions and 251 deletions

View File

@@ -7,8 +7,8 @@ import (
)
type Routing interface {
AddRouteVia(destination net.IPNet, gateway net.IP, iface string) error
DeleteRouteVia(destination net.IPNet) (err error)
Setup() (err error)
TearDown() error
DefaultRoute() (defaultInterface string, defaultGateway net.IP, err error)
LocalSubnet() (defaultSubnet net.IPNet, err error)
VPNDestinationIP() (ip net.IP, err error)