Disable mDNS IP masking
In this article we describe how to manually disable mDNS IP masking for browsers on Windows machines via the registry. To clarify, we will not be disabling mDNS itself, but its IP obfuscation function in regard to WebRTC, specifically just for the Microsoft eCDN domain.
Note
Alternative methods via the browser's UI have recently changed and may no longer be available.
Another perspective
As the concept can be a bit confusing, it may be more accurate to say that we're allowing WebRTC to expose the IP to Javascript in our domain on a per browser basis.
Purpose
This configuration change is a required component for enabling a browser-based client to participate in peering. Without this change, browser policy obfuscates the computer's local IP address from the Javascript layer, which is essential for direct p2p in organizational networks.
Typically, mDNS's IP masking is first disabled manually on an individual basis for the testing and validating of Microsoft eCDN's P2P solution on a small-scale test set. Next, customers often choose to proceed to using Group Policy or an endpoint management system such as SCCM or Intune to make the change en mass across their environment.
Note
No such configuration change requirement applies to the Teams Desktop application as it already has access to the host computer's IP address.
Registry Keys
| Registry element | Value |
|---|---|
| Path for Edge | HKEY_LOCAL_MACHINE\\SOFTWARE\\Policies\\Microsoft\\Edge\\ |
| Path for Chrome | HKEY_LOCAL_MACHINE\\SOFTWARE\\Policies\\Google\\Chrome\\ |
| Key name | WebRtcLocalIpsAllowedUrls |
| Value name | 1 or other numeric value |
| Value | *.ecdn.microsoft.com |
Common issue
The key for the required REG_SZ (string) value might not exist.
Example scenario
Here we see that a subkey is not present in the hierarchy under the Edge key as expected.
In this particular scenario, only the WebRtcLocalIpsAllowedUrls key is missing but it's also plausible for a key further up in the hierarchy to be missing such as "Edge", "Chrome", or "Google", even if the corresponding browser is installed.
Solution
The steps to resolve this scenario are straight forward.
Create the missing keys.
Input key name.
Continue creating missing keys down the hierarchy as necessary.
Lastly, in the
WebRtcLocalIpsAllowedUrlskey, create the string value, setting value name to1or the next numerical value in an already existing sequence, and value data to*.ecdn.microsoft.com.
Important
Remember to restart the browser to apply the changes.
Tip
To quickly and easily restart the browser, you can use one of the following shortcut URLs.
edge://restart
chrome://restart
Complete! mDNS is now disabled on Edge for the Microsoft eCDN domain.