Local Connections Using Microsoft Edge

SocketTools includes several server components, including a multi-threaded HTTP server. Initial testing is often done with the client and server connecting to one another on the local system, rather than over the Internet. When using the Chrome, Firefox or Internet Explorer browsers, the connection to the local server is successful. However, connection attempts fail when using the Microsoft Edge browser on Windows 10.

More Information

The SocketTools server components can be configured to listen for connections that can only be made on the local system. This is done by having the server listen for connections using the localhost address (also known as the loopback address). For IPv4 connections, this is 127.0.0.1 and for IPv6 it is ::1

There are several advantages to this approach when it comes to initial testing of a server application. By using the localhost address, it bypasses most firewall restrictions, since firewalls are typically configured to permit connections between local clients and servers. It also allows the server to be tested in an environment where it's not necessary to have a static external IP address or be concerned with NAT router configurations.

For the HTTP server component, the application only needs to configure the component to listen on the "localhost" address and browser can be used to connect to the server at http://localhost/ or https://localhost/ depending on whether security is enabled. This works for most browsers, however, the Microsoft Edge browser may fail to connect to the server. This is because Edge is a Universal Windows Platform (UWP) app that normally executes in a network isolation mode which blocks localhost connections.

To enable Edge to connect to your server listening on the local system, first close any open instances of Edge that you have running. Then open an Administrative command prompt and enter the following command:

CheckNetIsolation LoopbackExempt -a -n=Microsoft.MicrosoftEdge_8wekyb3d8bbwe

You should get an "OK" message in response to the command. Next, open Edge and enter about:flags in the address bar. Make sure that the "Allow localhost loopback" option is checked, and if not, enable it. Now you should be able to connect to your local server using the Edge browser.

See Also

Creating a Certificate Using MakeCert
Creating a Certificate Using OpenSSL
Connections Fail Using Test Certificate

Shopping Cart
Scroll to Top