summaryrefslogtreecommitdiffstats
path: root/src/etc
diff options
context:
space:
mode:
Diffstat (limited to 'src/etc')
-rw-r--r--src/etc/inc/vpn.inc14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/etc/inc/vpn.inc b/src/etc/inc/vpn.inc
index 4ecedaf..b999ea0 100644
--- a/src/etc/inc/vpn.inc
+++ b/src/etc/inc/vpn.inc
@@ -927,10 +927,18 @@ EOD;
$rightsourceip = NULL;
if (isset($ph1ent['mobile'])) {
+ $rightsourceips = array();
if (!empty($a_client['pool_address'])) {
- $rightsourceip = "\trightsourceip = {$a_client['pool_address']}/{$a_client['pool_netbits']}\n";
- } elseif ($ph1ent['authentication_method'] == "eap-radius") {
- $rightsourceip = "\trightsourceip = %radius\n";
+ $rightsourceips[] = "{$a_client['pool_address']}/{$a_client['pool_netbits']}";
+ }
+ if (!empty($a_client['pool_address_v6'])) {
+ $rightsourceips[] = "{$a_client['pool_address_v6']}/{$a_client['pool_netbits_v6']}";
+ }
+ if ($ph1ent['authentication_method'] == "eap-radius" && !count($rightsourceips)) {
+ $rightsourceips[] = "%radius";
+ }
+ if (count($rightsourceips)) {
+ $rightsourceip = "\trightsourceip = " . implode(',', $rightsourceips) . "\n";
}
}
OpenPOWER on IntegriCloud