diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2007-03-14 19:08:47 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2007-03-14 19:08:47 +0000 |
commit | ee5060449502c103b83c05dcfa794a55f40789ea (patch) | |
tree | a9a3ac467e9ea81685261aa04171c3c6721f1fe6 /etc | |
parent | fb7a98e96f9395932e44d6a63cb887a7709e1150 (diff) | |
download | pfsense-ee5060449502c103b83c05dcfa794a55f40789ea.zip pfsense-ee5060449502c103b83c05dcfa794a55f40789ea.tar.gz |
Fix ticket #1265
Multiple openvpn clients all attempt to bind to same local port
Diffstat (limited to 'etc')
-rw-r--r-- | etc/inc/openvpn.inc | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/etc/inc/openvpn.inc b/etc/inc/openvpn.inc index 87a4516..d00d034 100644 --- a/etc/inc/openvpn.inc +++ b/etc/inc/openvpn.inc @@ -218,7 +218,6 @@ daemon keepalive 10 60 ping-timer-rem persist-tun -lport $lport persist-key dev tun proto $proto @@ -259,6 +258,7 @@ EOD; // The port we'll listen at $openvpn_conf .= "lport {$settings['local_port']}\n"; + } else { // $mode == client @@ -267,6 +267,11 @@ EOD; if ($settings['auth_method'] == 'pki') $openvpn_conf .= "client\n"; + if ($settings['use_dynamicport']) $openvpn_conf .= "nobind\n"; + else + // The port we'll listen at + $openvpn_conf .= "lport {$lport}\n"; + if (!empty($settings['interface_ip'])) { // Configure the IPs according to the address pool list($ip, $mask) = explode('/', $settings['interface_ip']); @@ -451,4 +456,4 @@ function openvpn_print_javascript2() { EOD; print($javascript); } -?>
\ No newline at end of file +?> |