Further testing showed that this works as expected. A packet capture shows the RA source as the IP Alias VIP and the client (also pfSense) used said VIP as the default gateway. Testing was also successful with an IP Alias VIP that had a CARP parent.
diff --git a/src/etc/inc/services.inc b/src/etc/inc/services.inc
index 12aaf30b8d..84dbafa8aa 100644
--- a/src/etc/inc/services.inc
+++ b/src/etc/inc/services.inc
@@ -75,9 +75,15 @@ function services_radvd_configure($blacklist = array()) {
$racarpif = false;
$rasrcaddr = "";
- /* check if binding to CARP IP */
if (!empty($dhcpv6ifconf['rainterface']) && strstr($dhcpv6ifconf['rainterface'], "_vip")) {
- if (get_carp_interface_status($dhcpv6ifconf['rainterface']) == "MASTER") {
+ /* check if binding to CARP IP */
+ $carpstatus = get_carp_interface_status($dhcpv6ifconf['rainterface']);
+ if ($carpstatus == "") {
+ $rasrcaddr = get_configured_vip_ipv6($dhcpv6ifconf['rainterface']);
+ if (!is_linklocal($rasrcaddr)) {
+ $rasrcaddr = "";
+ }
+ } elseif ($carpstatus == "MASTER") {
if (is_linklocal(get_configured_vip_ipv6($dhcpv6ifconf['rainterface']))) {
$rasrcaddr = get_configured_vip_ipv6($dhcpv6ifconf['rainterface']);
} else {
diff --git a/src/usr/local/www/services_radvd.php b/src/usr/local/www/services_radvd.php
index f8b100eea4..aceb50f5ee 100644
--- a/src/usr/local/www/services_radvd.php
+++ b/src/usr/local/www/services_radvd.php
@@ -355,23 +355,32 @@ $section->addInput(new Form_Select(
$priority_modes
))->setHelp(gettext('Select the Priority for the RA Daemon.'));
-$carplist = get_configured_vip_list("inet6", VIP_CARP);
+$viplist = get_configured_vip_list("inet6");
-$carplistif = array();
+$viplistif = array();
-if (count($carplist) > 0) {
- foreach ($carplist as $ifname => $vip) {
- if (get_configured_vip_interface($ifname) == $if) {
- $carplistif[$ifname] = $vip;
+if (count($viplist) > 0) {
+ foreach ($viplist as $ifname => $vip) {
+ $parentinterface = get_configured_vip_interface($ifname);
+ if (substr($parentinterface, 0, 4) == "_vip") {
+ // IP Alias VIP with CARP parent.
+ $parentinterface = get_configured_vip_interface($parentinterface);
+ }
+ if ($parentinterface == $if) {
+ $viplistif[$ifname] = $vip;
}
}
}
-if (count($carplistif) > 0) {
+if (count($viplistif) > 0) {
$iflist = array();
$iflist['interface'] = convert_friendly_interface_to_friendly_descr($if);
- foreach ($carplistif as $ifname => $vip) {
+ foreach ($viplistif as $ifname => $vip) {
+ // Show only LLAs.
+ if (!is_linklocal($vip)) {
+ continue;
+ }
$iflist[$ifname] = get_vip_descr($vip) . " - " . $vip;
}