Skip to content

Commit

Permalink
Update services_dhcpv6.php
Browse files Browse the repository at this point in the history
Adjusted to make use of new functions.
Correction to Maximum prefix delegation size, should be+1 not -1!
Removed duplicate ISP assigned prefix line
  • Loading branch information
Martin Wasley committed May 11, 2020
1 parent 88bb423 commit fa8b4c7
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions src/www/services_dhcpv6.php
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,9 @@ function reconfigure_dhcpd()
$prefix_array[6] = '0';
$prefix_array[7] = '0';
$wifprefix = Net_IPv6::compress(implode(':', $prefix_array));
$pdlen = calculate_ipv6_delegation_length($config['interfaces'][$if]['track6-interface']) - 1;
$pdlen = calculate_ipv6_delegation_length($config['interfaces'][$if]['track6-interface']);
$pdinfo = get_isp_pdinfo($config['interfaces'][$if]['track6-interface']);

}

?>
Expand Down Expand Up @@ -462,8 +464,12 @@ function show_netboot_config() {
</tr>
<?php if ($pdlen >= 0): ?>
<tr>
<td><i class="fa fa-info-circle text-muted"></i> <?=gettext("Available prefix delegation size");?></td>
<td><?= 64 - $pdlen ?></td>
<td><i class="fa fa-info-circle text-muted"></i> <?=gettext("ISP Assigned PD/Size");?></td>
<td><?=$pdinfo ?></td>
</tr>
<tr>
<td><i class="fa fa-info-circle text-muted"></i> <?=gettext("Maximum prefix delegation size");?></td>
<td><?= $pdlen+1 ?></td>
</tr>
<?php endif ?>
<?php endif ?>
Expand Down

0 comments on commit fa8b4c7

Please sign in to comment.