diff options
author | jim-p <jimp@pfsense.org> | 2016-12-02 14:41:30 -0500 |
---|---|---|
committer | jim-p <jimp@pfsense.org> | 2016-12-02 14:41:30 -0500 |
commit | f829a8d3258e377b778ac84a1f2f345b8a79b766 (patch) | |
tree | ec384e7f0be03938e07e1d53043771f05c87b863 /src/usr/local/sbin/ovpn-linkup | |
parent | 8ec7704086b79801fc4c58acc2d3de3d09bd6f05 (diff) | |
download | pfsense-f829a8d3258e377b778ac84a1f2f345b8a79b766.zip pfsense-f829a8d3258e377b778ac84a1f2f345b8a79b766.tar.gz |
OpenVPN populates IPv6 env vars now, so we can fetch them for the IPv6 gateway. Fixes #6016
Diffstat (limited to 'src/usr/local/sbin/ovpn-linkup')
-rwxr-xr-x | src/usr/local/sbin/ovpn-linkup | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/usr/local/sbin/ovpn-linkup b/src/usr/local/sbin/ovpn-linkup index ec0a240..0551974 100755 --- a/src/usr/local/sbin/ovpn-linkup +++ b/src/usr/local/sbin/ovpn-linkup @@ -28,10 +28,23 @@ if [ "${dev_type}" = "tun" ]; then else /bin/echo ${5} > /tmp/${1}_router fi + + if [ -n "${route_ipv6_gateway_1}" ]; then + /bin/echo ${route_ipv6_gateway_1} > /tmp/${1}_routerv6 + elif [ -n "${ifconfig_ipv6_remote}" ]; then + /bin/echo ${ifconfig_ipv6_remote} > /tmp/${1}_routerv6 + elif [ -n "${ifconfig_ipv6_local}" ]; then + /bin/echo ${ifconfig_ipv6_local} > /tmp/${1}_routerv6 + fi + else if [ -n "${route_vpn_gateway}" ]; then /bin/echo ${route_vpn_gateway} > /tmp/${1}_router fi + + if [ -n "${route_ipv6_gateway_1}" ]; then + /bin/echo ${route_ipv6_gateway_1} > /tmp/${1}_routerv6 + fi fi /usr/bin/touch /tmp/${1}up |