diff --git a/src/etc/inc/interfaces.inc b/src/etc/inc/interfaces.inc
index e26c2997a..80398f3f2 100644
--- a/src/etc/inc/interfaces.inc
+++ b/src/etc/inc/interfaces.inc
@@ -390,6 +390,8 @@ function interface_bridge_configure(&$bridge, $checkmember = 0)
$bridge['bridgeif'] = $bridgeif;
}
+ mwexecf('/sbin/ifconfig %s inet6 %sauto_linklocal', array($bridgeif, isset($bridge['linklocal']) ? '' : '-'));
+
$checklist = get_configured_interface_with_descr();
/* Add interfaces to bridge */
diff --git a/src/www/interfaces_bridge.php b/src/www/interfaces_bridge.php
index a561ba920..cd29edc8c 100644
--- a/src/www/interfaces_bridge.php
+++ b/src/www/interfaces_bridge.php
@@ -1,36 +1,35 @@
=gettext("Interface");?>
=gettext("Members");?>
=gettext("Description");?>
+ =gettext("Link-local");?>
@@ -130,7 +129,7 @@ $main_buttons = array(
$ifdescrs = get_configured_interface_with_descr();
foreach ($a_bridges as $bridge): ?>
- =strtoupper($bridge['bridgeif']);?>
+ = $bridge['bridgeif'] ?>
=$bridge['descr'];?>
+ = !empty($bridge['linklocal']) ? gettext('On') : gettext('Off') ?>
@@ -167,4 +167,7 @@ $main_buttons = array(
-
+
+ $bdescr) {
}
}
-
if ($_SERVER['REQUEST_METHOD'] === 'GET') {
// read form data
if (!empty($a_bridges[$_GET['id']])) {
@@ -57,8 +56,10 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
$pconfig[$fieldname] = null;
}
}
+
// bool fields
- $pconfig['enablestp'] = isset($a_bridges[$id]['enablestp']);
+ $pconfig['enablestp'] = !empty($a_bridges[$id]['enablestp']);
+ $pconfig['linklocal'] = !empty($a_bridges[$id]['linklocal']);
// simple array fields
$array_fields = array('members', 'stp', 'edge', 'autoedge', 'ptp', 'autoptp', 'static', 'private');
@@ -144,7 +145,12 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
if (count($input_errors) == 0) {
$bridge = array();
- $bridge['enablestp'] = !empty($pconfig['enablestp']);
+ // booleans
+ foreach (['enablestp', 'linklocal'] as $fieldname) {
+ if (!empty($pconfig[$fieldname])) {
+ $bridge[$fieldname] = true;
+ }
+ }
// 1 on 1 copy
$copy_fields = array('descr', 'maxaddr', 'timeout', 'bridgeif', 'maxage','fwdelay', 'hellotime', 'priority', 'proto', 'holdcnt');
foreach ($copy_fields as $fieldname) {
@@ -272,6 +278,18 @@ $(document).ready(function() {
+
+ = gettext('Link-local address') ?>
+
+ />
+ = gettext('Enable link-local address') ?>
+
+ = gettext('By default, link-local addresses for bridges are disabled. You can enable them manually using this option. ' .
+ 'However, when a bridge interface has IPv6 addresses, IPv6 addresses on a member interface will be automatically ' .
+ 'removed before the interface is added.') ?>
+
+
+
@@ -636,4 +654,7 @@ $(document).ready(function() {
-
+
+