diff --git a/RELEASE_NOTES b/RELEASE_NOTES index 0c084fbba..7eb26be37 100644 --- a/RELEASE_NOTES +++ b/RELEASE_NOTES @@ -36,6 +36,9 @@ New user-visible features use specialized L4 protocols according to the interface. - (internet) Ipv6Address::IsAllHostsMulticast() is now deprecated. FF02::3 is not in the official reserved IPv6 multicast address list. +- (internet) Ipv6Address::IsAll[Nodes,Routers]Multicast() now checks the address + scope beyond the simple link-local. Nodes are checked for Interface-Local, Link-Local + and Realm-Local, Routers for the above plus Site-Local. Bugs fixed ---------- diff --git a/src/network/utils/ipv6-address.cc b/src/network/utils/ipv6-address.cc index 0080d0b78..33816e6ea 100644 --- a/src/network/utils/ipv6-address.cc +++ b/src/network/utils/ipv6-address.cc @@ -671,15 +671,20 @@ bool Ipv6Address::IsSolicitedMulticast () const bool Ipv6Address::IsAllNodesMulticast () const { NS_LOG_FUNCTION (this); - static Ipv6Address allnodes ("ff02::1"); - return (*this == allnodes); + static Ipv6Address allNodesI ("ff01::1"); + static Ipv6Address allNodesL ("ff02::1"); + static Ipv6Address allNodesR ("ff03::1"); + return (*this == allNodesI || *this == allNodesL || *this == allNodesR); } bool Ipv6Address::IsAllRoutersMulticast () const { NS_LOG_FUNCTION (this); - static Ipv6Address allrouters ("ff02::2"); - return (*this == allrouters); + static Ipv6Address allroutersI ("ff01::2"); + static Ipv6Address allroutersL ("ff02::2"); + static Ipv6Address allroutersR ("ff03::2"); + static Ipv6Address allroutersS ("ff05::2"); + return (*this == allroutersI || *this == allroutersL || *this == allroutersR || *this == allroutersS); } bool Ipv6Address::IsAllHostsMulticast () const