At the ethernet layer, hosts generally listen for packets destined for specific MAC addresses. This includes unicast, broadcast, and multicast addresses. Broadcast & Multicast addresses have special handling in network switches. Cheap switches will just broadcast packets with a destination MAC that is a multicast or broadcast address.
ff:ff:ff:ff:ff:ff is the broadcast MAC address
01:00:5e:XX:XX:XX is the multicast MAC address range. There is a trivial mapping from multicast IPs in the
18.104.22.168/4 range (22.214.171.124-126.96.36.199): just take the lower 23 bits of the IP, and prepend with the OUI
01:00:5e: (the collisions in the top 5 bits of the IP and the missing bit have historical reasons).
Sending an ICMP PING out for an IP associated with a broadcast or multicast MAC address will generally cause all hosts listening for that MAC to respond. Depending on the client you are using, you may have to pass a specific broadcast flag or have admin privileges.
You can lookup registered multicast addresses here: https://www.iana.org/assignments/multicast-addresses/multicast-addresses.xhtml#multicast-addresses-12
However, there are services that pick random multicast addresses, or aren't registered.
In your output:
188.8.131.52 - IGMP
184.108.40.206 - mDNS
220.127.116.11 - Link-local Multicast Name Resolution
18.104.22.168 - Simple Service Discovery Protocol (SSDP)
Python transformation for Multicast IPv4 address to Multicast MAC:
def multicast_ipv4_to_mac(ipaddr_as_u32, multicast_oui='01005e'):
return "%s%06x" % (multicast_oui, ipaddr_as_u32 & 0x7FFFFF)
# Example, using ip2int from https://stackoverflow.com/questions/5619685/conversion-from-ip-string-to-integer-and-backward-in-python