diff --git a/src/devices/nm-device.c b/src/devices/nm-device.c index 908f8000b7..7af5de925a 100644 --- a/src/devices/nm-device.c +++ b/src/devices/nm-device.c @@ -11393,7 +11393,8 @@ queued_ip6_config_change (gpointer user_data) * ("Addressing Model"): "All interfaces are required to have at least * one link-local unicast address". */ - if (priv->ip6_config && nm_ip6_config_get_num_addresses (priv->ip6_config)) + if ( priv->ip6_config + && nm_ip6_config_get_num_addresses (priv->ip6_config)) need_ipv6ll = TRUE; if (need_ipv6ll) diff --git a/src/ndisc/nm-lndp-ndisc.c b/src/ndisc/nm-lndp-ndisc.c index 70200ed34c..9c7d3c4dfa 100644 --- a/src/ndisc/nm-lndp-ndisc.c +++ b/src/ndisc/nm-lndp-ndisc.c @@ -195,6 +195,10 @@ receive_ra (struct ndp *ndp, struct ndp_msg *msg, gpointer user_data) continue; nm_utils_ip6_address_clear_host_address (&r_network, ndp_msg_opt_prefix (msg, offset), r_plen); + if ( IN6_IS_ADDR_UNSPECIFIED (&r_network) + || IN6_IS_ADDR_LINKLOCAL (&r_network)) + continue; + if (ndp_msg_opt_prefix_flag_on_link (msg, offset)) { NMNDiscRoute route = { .network = r_network, diff --git a/src/ndisc/nm-ndisc.c b/src/ndisc/nm-ndisc.c index ede655dd95..ba61cb1125 100644 --- a/src/ndisc/nm-ndisc.c +++ b/src/ndisc/nm-ndisc.c @@ -351,6 +351,8 @@ nm_ndisc_add_address (NMNDisc *ndisc, const NMNDiscAddress *new) nm_assert (new); nm_assert (new->timestamp > 0 && new->timestamp < G_MAXINT32); + nm_assert (!IN6_IS_ADDR_UNSPECIFIED (&new->address)); + nm_assert (!IN6_IS_ADDR_LINKLOCAL (&new->address)); for (i = 0; i < rdata->addresses->len; i++) { NMNDiscAddress *item = &g_array_index (rdata->addresses, NMNDiscAddress, i);