Skip to content

Commit

Permalink
Always add a link-local of fe80::1:1 when the interface is set to tra…
Browse files Browse the repository at this point in the history
…ck6. This allows webui access over IPv6 to a easy address.

Make a shortcut in the get_failover_interface() function to get_real_interface() if we find the interface in $config.
  • Loading branch information
smos committed Jun 4, 2012
1 parent 4264284 commit e90c833
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions etc/inc/interfaces.inc
Original file line number Diff line number Diff line change
Expand Up @@ -3012,6 +3012,10 @@ function interface_track6_configure($interface = "lan") {
return(false);
}

/* always configure a link-local of fe80::1:1 on the track6 interfaces */
$realif = get_real_interface($interface);
mwexec("/sbin/ifconfig {$realif} inet6 fe80::1:1%{$realif}");

$type = $config['interfaces'][$wancfg['track6-interface']]['ipaddrv6'];
switch($type) {
case "6to4":
Expand Down Expand Up @@ -4770,6 +4774,12 @@ function interfaces_staticarp_configure($if) {

function get_failover_interface($interface) {
global $config;
/* shortcut to get_real_interface if we find it in the config */
if(is_array($config['interfaces'][$interface])) {
$wanif = get_real_interface($interface);
return $wanif;
}

/* compare against gateway groups */
$a_groups = return_gateway_groups_array();
if(is_array($a_groups[$interface])) {
Expand Down

0 comments on commit e90c833

Please sign in to comment.