[webkit-changes] [WebKit/WebKit] 8ceefd: Network process should be able to resolve its own ...

youennf noreply at github.com
Fri Mar 22 11:00:56 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 8ceefda7940b252c0f7e190fa586232cce3b3368
      https://github.com/WebKit/WebKit/commit/8ceefda7940b252c0f7e190fa586232cce3b3368
  Author: Youenn Fablet <youenn at apple.com>
  Date:   2024-03-22 (Fri, 22 Mar 2024)

  Changed paths:
    M Source/WebKit/NetworkProcess/webrtc/NetworkMDNSRegister.cpp
    M Source/WebKit/NetworkProcess/webrtc/NetworkMDNSRegister.h
    M Source/WebKit/NetworkProcess/webrtc/NetworkRTCMonitor.cpp
    M Source/WebKit/NetworkProcess/webrtc/NetworkRTCMonitor.h
    M Source/WebKit/NetworkProcess/webrtc/NetworkRTCProvider.cpp
    M Source/WebKit/Shared/RTCNetwork.h

  Log Message:
  -----------
  Network process should be able to resolve its own registered mDNS names
https://bugs.webkit.org/show_bug.cgi?id=271368
rdar://112834753

Reviewed by Chris Dumez.

Store the registered mdns names in a HashSet.
In case of a mDNS resolution, we check the hashset and if there is a match, we use the current local address directly.
This ensures that mDNS resolution with Safari works even if mDNS registration fails.
We add a mechanism to remove the mdns names from the HashSet whenever the document goes away, to keep the same mDNS lifetime as before.

* Source/WebKit/NetworkProcess/webrtc/NetworkMDNSRegister.cpp:
(WebKit::NetworkMDNSRegister::unregisterMDNSNames):
(WebKit::NetworkMDNSRegister::hasRegisteredName):
(WebKit::NetworkMDNSRegister::registerMDNSName):
* Source/WebKit/NetworkProcess/webrtc/NetworkMDNSRegister.h:
* Source/WebKit/NetworkProcess/webrtc/NetworkRTCProvider.cpp:
(WebKit::NetworkRTCProvider::createResolver):
* Source/WebKit/Shared/RTCNetwork.h:
(WebKit::RTC::Network::IPAddress::isUnspecified const):

Canonical link: https://commits.webkit.org/276556@main



To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications


More information about the webkit-changes mailing list