Skip to main content

6. Implementation Guidance

6. Implementation Guidance

Browsers (User Agents) SHOULD implement the mDNS technique to protect private IP addresses while preserving local connectivity.

  • Handling mDNS: When generating a host candidate for a private IP, the UA generates a random UUID, registers it via mDNS, and uses <uuid>.local as the address in the ICE candidate.
  • Resolution: When a UA receives a candidate with a .local hostname, it attempts to resolve it using mDNS. If resolution succeeds (meaning the peer is on the same LAN), it proceeds with connectivity checks.

This mechanism ensures that:

  1. Remote peers (not on the LAN) cannot learn the private IP.
  2. Local peers (on the LAN) can still connect directly.
  3. The application JavaScript sees only the UUID hostname, not the IP.