Révision 2cff71c4
Ajouté par Renato Botelho il y a plus de 9 ans
etc/inc/filter.inc | ||
---|---|---|
1366 | 1366 |
if($oc['sa']) { |
1367 | 1367 |
$tonathosts[] = "{$oc['sa']}/{$oc['sn']}"; |
1368 | 1368 |
$descriptions[] = $oc['descr']; |
1369 |
if (isset($oc['vips']) && is_array($oc['vips'])) { |
|
1370 |
$if_subnets = array("{$oc['sa']}/{$oc['sn']}"); |
|
1371 |
foreach ($oc['vips'] as $vip) { |
|
1372 |
if (!is_ipaddrv4($vip['ip'])) |
|
1373 |
continue; |
|
1374 |
|
|
1375 |
foreach ($if_subnets as $subnet) |
|
1376 |
if (ip_in_subnet($vip['ip'], $subnet)) |
|
1377 |
continue 2; |
|
1378 |
|
|
1379 |
$network = gen_subnet($vip['ip'], $vip['sn']); |
|
1380 |
$tonathosts[] = $network . '/' . $vip['sn']; |
|
1381 |
$descriptions[] = "Virtual IP ({$oc['descr']})"; |
|
1382 |
$if_subnets[] = $network . '/' . $vip['sn']; |
|
1383 |
unset($network); |
|
1384 |
} |
|
1385 |
unset($if_subnets); |
|
1386 |
} |
|
1369 | 1387 |
} |
1370 | 1388 |
} |
1371 | 1389 |
|
Formats disponibles : Unified diff
Take virtual IPs into consideration for automatic outbound NAT rules, it should now fix #983