UdpClient JoinMulticastGroup TTL > 1?
Hi all,
I have a couple questions about the TTL parameter for JoinMulticastGroup. The documentation says the TTL parameter is measured in router hops. I set the parameter to 10, but when I examine the IGMPv2 join packet in Wireshark, I see the "Time to live" = 1, and from my research, I believe the TTL for IGMP join packet can only be 1 as designed.
The response in this archived post also confirms TTL can only be 1: https://social.msdn.microsoft.com/Forums/en-US/adff7ed7-5c93-4dc4-92a4-6dff78108418/udpclientjoinmulticastgroup-ignores-ttl-value?forum=ncl
If my belief is true that the TTL of the join packet is always 1, then what is the TTL parameter of the JoinMulticastGroup really for?
Here is my code so far
UdpClient udpClient = new UdpClient();
// Creates an IPAddress to use to join and drop the multicast group.
IPAddress multicastIpAddress = IPAddress.Parse("239.192.16.107");
udpClient.Client.SetSocketOption(SocketOptionLevel.IP, SocketOptionName.IpTimeToLive, 10);
udpClient.Client.SetSocketOption(SocketOptionLevel.IP, SocketOptionName.MulticastTimeToLive, 10);
udpClient.Ttl = 10;
// The packet dies after 10 router hops.
udpClient.JoinMulticastGroup(multicastIpAddress, 10);