diff options
author | PiBa-NL <pba_2k3@yahoo.com> | 2012-09-22 23:23:58 +0200 |
---|---|---|
committer | PiBa-NL <pba_2k3@yahoo.com> | 2012-09-22 23:23:58 +0200 |
commit | c8bb7f1527a99c69784ab6c01d9050adcde6a8a0 (patch) | |
tree | 409060c5976c75cc63113273f6440425913e8796 /etc | |
parent | ea68f6cc92fb6167c084d6786984bdf35caef132 (diff) | |
download | pfsense-c8bb7f1527a99c69784ab6c01d9050adcde6a8a0.zip pfsense-c8bb7f1527a99c69784ab6c01d9050adcde6a8a0.tar.gz |
Allow for changing OpenVPN TUN to TAP device mode without reboot.
Diffstat (limited to 'etc')
-rw-r--r-- | etc/inc/openvpn.inc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/etc/inc/openvpn.inc b/etc/inc/openvpn.inc index bddb5c8..8416264 100644 --- a/etc/inc/openvpn.inc +++ b/etc/inc/openvpn.inc @@ -710,7 +710,12 @@ function openvpn_delete($mode, & $settings) { $vpnid = $settings['vpnid']; $mode_id = $mode.$vpnid; - $tunname = "tun{$vpnid}"; + if (isset($settings['dev_mode'])) + $tunname = "{$settings['dev_mode']}{$vpnid}"; + else { /* defaults to tun */ + $tunname = "tun{$vpnid}"; + } + if ($mode == "server") $devname = "ovpns{$vpnid}"; else |