Always resolve localhost to loopback address

This always resolves "localhost" to a loopback address which
has security benefits such as preventing a malicious dns server
redirecting local connections and allows software to assume
it is a secure hostname.

This is being adopted by web browsers:

- https://w3c.github.io/webappsec-secure-contexts/
- https://groups.google.com/a/chromium.org/forum/#!msg/blink-dev/RC9dSw-O3fE/E3_0XaT0BAAJ
- https://chromium.googlesource.com/chromium/src.git/+/8da2a80724a9b896890602ff77ef2216cb951399
- https://bugs.webkit.org/show_bug.cgi?id=171934
- https://tools.ietf.org/html/draft-west-let-localhost-be-localhost-06
12 jobs for wip/tingping/localhost-is-local in 14 minutes and 32 seconds (queued for 3 seconds)
latest
Status Job ID Name Coverage
  Build
passed #281072
cross-android_api21_arm64

00:01:20

passed #281073
cross-android_api28_arm64

00:01:13

passed #281074
cross-mingw64

00:02:54

passed #281080
fedora-x86_64

00:04:42

passed #281077
freebsd-11
freebsd-11-x86_64

00:04:02

passed #281071
G_DISABLE_ASSERT

00:02:01

failed #281082
win32
msys2-mingw32

00:03:07

passed #281076
win32
vs2017-x64

00:09:02

failed #281070
fedora-x86_64

00:05:04

failed #281081
win32
msys2-mingw32

00:03:05

failed #281075
win32
msys2-mingw32

00:02:55

 
  Coverage
skipped #281078
coverage
 
Name Stage Failure
failed
msys2-mingw32 Build
WARNING: _build/msys2-mingw32-report.xml: no matching files 
_coverage/: found 1 matching files

WARNING: Failed to load system CertPool:crypto/x509: system root pool is not available on Windows
Uploading artifacts to coordinator... ok
id=281082 responseStatus=201 Created token=GpkWHjUe
Uploading artifacts...
Runtime platform
arch=amd64 os=windows pid=536 revision=de08a4bb version=11.9.1
WARNING: _build/msys2-mingw32-report.xml: no matching files
ERROR: No files to upload
ERROR: Job failed: exit status 1