summaryrefslogtreecommitdiffstats
path: root/etc/inc/services.inc
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2013-03-18 15:54:17 +0000
committerErmal <eri@pfsense.org>2013-03-18 15:54:17 +0000
commit6fb667365d508ab544b5279ade8272aed72d51f9 (patch)
tree7dbf1ba06c2626876af4ad067836ba8b0e06a2e7 /etc/inc/services.inc
parente9d156fd1b9620b72ebfc8e875a1d4d689a14734 (diff)
downloadpfsense-6fb667365d508ab544b5279ade8272aed72d51f9.zip
pfsense-6fb667365d508ab544b5279ade8272aed72d51f9.tar.gz
Correct get_interface_subnetv6 and use get_interface_ipv6 during dhcp config generation. Also initialize some arrays to avoid warnings
Diffstat (limited to 'etc/inc/services.inc')
-rw-r--r--etc/inc/services.inc4
1 files changed, 3 insertions, 1 deletions
diff --git a/etc/inc/services.inc b/etc/inc/services.inc
index 81d2ee6..702ec90 100644
--- a/etc/inc/services.inc
+++ b/etc/inc/services.inc
@@ -893,7 +893,7 @@ function services_dhcpdv6_configure() {
/* we add a fake entry for interfaces that are set to track6 another WAN */
foreach ($Iflist as $ifname) {
$realif = get_real_interface($ifname);
- $ifcfgipv6 = find_interface_ipv6($realif);
+ $ifcfgipv6 = get_interface_ipv6($ifname);
if(!is_ipaddrv6($ifcfgipv6))
continue;
$ifcfgipv6 = Net_IPv6::getNetmask($ifcfgipv6, 64);
@@ -906,6 +906,7 @@ function services_dhcpdv6_configure() {
$dhcpdv6cfg[$ifname]['enable'] = true;
/* range */
$ifcfgipv6arr[7] = "1000";
+ $dhcpdv6cfg[$ifname]['range'] = array();
$dhcpdv6cfg[$ifname]['range']['from'] = Net_IPv6::compress(implode(":", $ifcfgipv6arr));
$ifcfgipv6arr[7] = "2000";
$dhcpdv6cfg[$ifname]['range']['to'] = Net_IPv6::compress(implode(":", $ifcfgipv6arr));;
@@ -914,6 +915,7 @@ function services_dhcpdv6_configure() {
$pdlenmax = $pdlen;
$pdlenhalf = $pdlenmax -1;
$pdlenmin = (64 - ceil($pdlenhalf / 4));
+ $dhcpdv6cfg[$ifname]['prefixrange'] = array();
$dhcpdv6cfg[$ifname]['prefixrange']['prefixlength'] = $pdlenmin;
/* set the delegation start to half the current address block */
OpenPOWER on IntegriCloud