mirror of
https://github.com/pfsense/pfsense.git
synced 2025-10-26 11:38:35 +00:00
Correct some of the logic in the get_vpns_list() that was committed in the
last revision.
This commit is contained in:
parent
ed2fba4db6
commit
539fcd7ed6
@ -350,10 +350,11 @@ function get_vpns_list() {
|
||||
$vpns_arr = array();
|
||||
|
||||
/* ipsec */
|
||||
if ($config['ipsec']['phase2'])
|
||||
foreach ($config['ipsec']['phase2'] as $ph2ent)
|
||||
if($ph2ent['remoteid']['address'])
|
||||
$vpns_arr[] = $ph2ent['remoteid']['address'] . "/" . $ph2ent['remoteid']['netbits'];
|
||||
if (isset($config['ipsec']['enable']))
|
||||
if (is_array($config['ipsec']['phase2']))
|
||||
foreach ($config['ipsec']['phase2'] as $ph2ent)
|
||||
if(!$ph2ent['mobile'])
|
||||
$vpns_arr[] = ipsec_idinfo_to_cidr($ph2ent['remoteid']);
|
||||
|
||||
/* openvpn */
|
||||
foreach (array('client', 'server') as $type)
|
||||
@ -2906,4 +2907,4 @@ function return_vpn_subnet($adr)
|
||||
|
||||
}
|
||||
|
||||
?>
|
||||
?>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user