If ("WebRtcLocalhostIpHandling") Then RegKey.DeleteValue("WebRtcLocalhostIpHandling") The same code works perfectly for Edge: Dim RegKey = My.("Software\Policies\Microsoft\Edge") If ("WebView2") Then RegKey.DeleteSubKey("WebView2") I run the following code on form close to clean up Dim RegKey = My.("Software\Policies\Microsoft\Edge") RegKey.SetValue("WebRtcLocalhostIpHandling", "disable_non_proxied_udp", ) Dim RegKey = My.("Software\Policies\Microsoft\Edge\WebView2") Setting the WebRtcLocalhostIpHandling registry key to disable_non_proxied_udp will prevent the IP from being leaked. This can be done at LocalMachine or CurrentUser Level. The simplest way to kill off WebRTC leaks in WebView2 is to change the policy in the registry when your app first starts up. ![]() This code demonstrates how to use WebView2 with an anonymous proxy and to prevent WebRTC leaks. I'm using Microsoft Edge with version 80.0.315.0 (Official build) canary (64-bit) on a Window 10. The above args won't work in the API CreateWebView2EnvironmentWithDetails(nullptr, nullptr, args, callback_handler) WCHAR args = TEXT("-edge-webview-switches=-disable-webrtc-hide-local-ips-with-mdns") WCHAR args = TEXT("-edge-webview-switches=-enable-webrtc-hide-local-ips-with-mdns=0") WCHAR args = TEXT("-edge-webview-switches=\"-enable-webrtc-hide-local-ips-with-mdns=0\"") WCHAR args = TEXT("-disable-webrtc-hide-local-ips-with-mdns") ![]() ![]() WCHAR args = TEXT("-enable-webrtc-hide-local-ips-with-mdns=0") I've tried the following values which don't work at all. I want to change the value of edge://flags/#enable-webrtc-hide-local-ips-with-mdns flag from 'Default' to 'Disabled'.Īccording to the MSDN doc, the API CreateWebView2EnvironmentWithDetails has an argument additionalBrowserArguments which can change chromium flags. I'm developing WebRTC application using Microsoft Edge WebView2.
0 Comments
Leave a Reply.AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |