Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > alt.comp.os.windows-10 > #96169 > unrolled thread

Hosts file entries.

Started byPeter Jason <pj@jostle.com>
First post2019-08-15 07:52 +1000
Last post2019-08-16 13:48 -0400
Articles 11 — 10 participants

Back to article view | Back to alt.comp.os.windows-10


Contents

  Hosts file entries. Peter Jason <pj@jostle.com> - 2019-08-15 07:52 +1000
    Re: Hosts file entries. "Mayayana" <mayayana@invalid.nospam> - 2019-08-14 18:14 -0400
    Re: Hosts file entries. Don Kuenz, KB7RPU <g@crcomp.net> - 2019-08-14 22:34 +0000
    Re: Hosts file entries.  Arlen George Holder <arlinggeorgeholder@nospam.net> - 2019-08-15 00:29 +0000
    Re: Hosts file entries. "s|b" <me@privacy.invalid> - 2019-08-15 18:29 +0200
      Re: Hosts file entries. "Carlos E.R." <robin_listas@es.invalid> - 2019-08-16 12:12 +0200
    Re: Hosts file entries. Peter Jason <pj@jostle.com> - 2019-08-16 11:36 +1000
      Re: Hosts file entries. Paul <nospam@needed.invalid> - 2019-08-16 03:39 -0400
        Re: Hosts file entries. notX <no.email@dummy.invalid> - 2019-08-16 11:42 -0500
      Re: Hosts file entries. MikeS <MikeS@fred.com> - 2019-08-16 17:39 +0100
        Re: Hosts file entries. Rabid Robot <rabid@rob.ot> - 2019-08-16 13:48 -0400

#96169 — Hosts file entries.

FromPeter Jason <pj@jostle.com>
Date2019-08-15 07:52 +1000
SubjectHosts file entries.
Message-ID<rf09lepjaifj6if6hqs42js9qc2v3qg7bl@4ax.com>
I am using the hosts file to block unwanted Internet sites, and the
following works so far. Win10 1903

*******************************
# Copyright (c) 1993-2009 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host
name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
#      102.54.94.97     rhino.acme.com          # source server
#       38.25.63.10     x.acme.com              # x client host

# localhost name resolution is handled within DNS itself.
#	127.0.0.1       localhost
#	::1             localhost

127.0.0.1	www.expressvpn.com
127.0.0.1	expressvpn.com
127.0.0.1	www.ladbrokes.com.au
127.0.0.1	ladbrokes.com.au
127.0.0.1	www.get-express-vpn.com
127.0.0.1	get-express-vpn.com
127.0.0.1	www.drazens.com
127.0.0.1	drazens.com
127.0.0.1	www.nutaku.net
127.0.0.1	nutaku.com
127.0.0.1	www.trazens.com
127.0.0.1	trazens.com
127.0.0.1	www.velocecdn.com
127.0.0.1	velocecdn.com

***********************************************************

Is this the correct way to do it; should some entries be on the same
line?

	

[toc] | [next] | [standalone]


#96170

From"Mayayana" <mayayana@invalid.nospam>
Date2019-08-14 18:14 -0400
Message-ID<qj215d$gne$1@dont-email.me>
In reply to#96169
"Peter Jason" <pj@jostle.com> wrote


|I am using the hosts file to block unwanted Internet sites, and the
| following works so far. Win10 1903
|

At the top you need:

127.0.0.1 localhost

Uncommented. Then for each entry it should be on a separate
line. Note that HOST distinguishes subdomains. What that means
is that expressvpn.com will not cover a1.expressvpn.com.
ads.doubleclick.net will not work to block ads2.doubleclick.net.

  Fortunately, most tracking and ad companies don't bother to
vary their URLs. But some do. It's for that reason that I strongly
suggest using Acrylic DNS proxy. Acrylic has its own HOST file
and allows wildcards.

  Acrylic takes a few steps to set up, but it's not complex. Once
installed, when something makes a DNS call to find the IP address
of a URL, Acrylic gets called instead of Windows. Acrylic then
makes the DNS call, if necessary, to the DNS server of your
choosing. With Acrylic you can use entries like:

127.0.0.1 *.doubleclick.net

 That single line will block all URLs that go to the top level
domain of doubleclick.net. That allows you to have a HOSTS
file that's much smaller while also being much more dependable.

  As an example, the following is what I use to block Google
alone. Google is fantastically successful at surrveillance. Nearly
all commercial sites use their tag manager and/or fonts and/or
javascript and/or ads. That means that unless you act, Google
knows nearly every webpage you visit. And of course Google is
only one sleazeball in this mess. There's Facebook, Amazon,
Akamai, Twitter, and lots of ad/tracking companies.

127.0.0.1 *.googlesyndication.com
127.0.0.1 *.googleadservices.com
127.0.0.1 *.googlecommerce.com
127.0.0.1 *.scorecardresearch.com
127.0.0.1 *.1e100.com
127.0.0.1 *.1e100.net
127.0.0.1 *.doubleclick.net
127.0.0.1 *.doubleclick.com
127.0.0.1 *.googletagservices.com
127.0.0.1 *.googletagmanager.com
127.0.0.1 *.google-analytics.com
127.0.0.1 google-analytics.com
127.0.0.1 fonts.googleapis.com
127.0.0.1 *.2mdn.net
127.0.0.1 googleadapis.l.google.com
127.0.0.1 *.gstatic.com
127.0.0.1 plusone.google.com
127.0.0.1 cse.google.com
127.0.0.1 www.google.com/cse
127.0.0.1 www.youtube-nocookie.com
127.0.0.1 *.appspot.com 

[toc] | [prev] | [next] | [standalone]


#96171

FromDon Kuenz, KB7RPU <g@crcomp.net>
Date2019-08-14 22:34 +0000
Message-ID<20190814f@crcomp.net>
In reply to#96169
Peter Jason <pj@jostle.com> wrote:
> I am using the hosts file to block unwanted Internet sites, and the
> following works so far. Win10 1903
>
> *******************************
> # Copyright (c) 1993-2009 Microsoft Corp.
> #
> # This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
> #
> # This file contains the mappings of IP addresses to host names. Each
> # entry should be kept on an individual line. The IP address should
> # be placed in the first column followed by the corresponding host
> name.
> # The IP address and the host name should be separated by at least one
> # space.
> #
> # Additionally, comments (such as these) may be inserted on individual
> # lines or following the machine name denoted by a '#' symbol.
> #
> # For example:
> #
> #      102.54.94.97     rhino.acme.com          # source server
> #       38.25.63.10     x.acme.com              # x client host
>
> # localhost name resolution is handled within DNS itself.
> #       127.0.0.1       localhost
> #       ::1             localhost
>
> 127.0.0.1       www.expressvpn.com
> 127.0.0.1       expressvpn.com
> 127.0.0.1       www.ladbrokes.com.au
> 127.0.0.1       ladbrokes.com.au
> 127.0.0.1       www.get-express-vpn.com
> 127.0.0.1       get-express-vpn.com
> 127.0.0.1       www.drazens.com
> 127.0.0.1       drazens.com
> 127.0.0.1       www.nutaku.net
> 127.0.0.1       nutaku.com
> 127.0.0.1       www.trazens.com
> 127.0.0.1       trazens.com
> 127.0.0.1       www.velocecdn.com
> 127.0.0.1       velocecdn.com
>
> ***********************************************************
>
> Is this the correct way to do it; should some entries be on the same
> line?

That's correct. In ancient days WXP took forever to timeout. So this
program below was written by me to correct the situation. Although it
used VC back in the day, it ought to be simple enough to port my app to
cygwin WIN32.

------------------------------------------------------------------------
#include <windows.h>
#include <process.h>
#include <stdio.h>
#include <time.h>

#define WM_USER_OPEN_IN_OUT WM_USER + 100  
#define WM_USER_DO_XCOPY WM_USER + 101  

HICON hIconState;
HINSTANCE hinst;
HWND hwnd;
static TCHAR szAppName[] = TEXT("CRCBack");

void thread(PVOID pvoid);
LRESULT CALLBACK wndProc(HWND, UINT, WPARAM, LPARAM);

void thread(PVOID pvoid)
{
  char buf[BUFLEN];
  int bufLen;
  char msg404[] = {
    "HTTP/1.1 404 Not Found\r\n"
    "Connection: close\r\n"
    "\r\n"
    "<!DOCTYPE HTML PUBLIC \"-//IETF//DTD HTML 2.0//EN\">\n"
    "<HTML><HEAD>\n"
    "<TITLE>404 Not Found</TITLE>\n"
    "</HEAD><BODY>\n"
    "<H1>Not Found</H1>\n"
    "The requested URL was not found on this server.<P>\n"
    "<HR>\n"
    "<ADDRESS>send404 server at 127.0.0.1 Port 80</ADDRESS>\n"
    "</BODY></HTML>\n\x0"
  };
  SOCKET sConnect;

  for (;;) {
    /* wait for next connection */
    sConnect = accept(s, NULL, NULL);
    if (sConnect == INVALID_SOCKET) {
      break;
    }

    /* receive GET message */
    if ((bufLen = recv(sConnect, buf, BUFLEN, 0)) < 0) {
      break;
    }

    /* send 404 message */
    if (send(sConnect, msg404, sizeof(msg404), 0) < 0) {
      break;
    }

    /* close connection */
    closesocket(sConnect);
    }
}

int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, PSTR szCmdLine, int iCmdShow)
{
  MSG msg;
  WNDCLASSA wndclass;

  hinst = hInstance;

  wndclass.style = CS_HREDRAW | CS_VREDRAW;
  wndclass.lpfnWndProc = wndProc;
  wndclass.cbClsExtra = 0;
  wndclass.cbWndExtra = 0;
  wndclass.hInstance = hInstance;
  wndclass.hIcon = LoadIcon(NULL, IDI_APPLICATION);
  wndclass.hCursor = LoadCursor(NULL, IDC_ARROW);
  wndclass.hbrBackground = (HBRUSH) GetStockObject(WHITE_BRUSH);
  wndclass.lpszMenuName = NULL;
  wndclass.lpszClassName = szAppName;

  if (!RegisterClass(&wndclass)) {
    MessageBox (NULL, TEXT("This program requires Windows NT!"), 
      szAppName, MB_ICONERROR);
    return 0;
  }
     
  hwnd = CreateWindow(szAppName, TEXT ("CRCBack"), WS_OVERLAPPEDWINDOW,
    CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT, CW_USEDEFAULT,
    NULL, NULL, hInstance, NULL);
  
  //ShowWindow(hwnd, SW_SHOW);
  //UpdateWindow(hwnd);

  PostMessage(hwnd, WM_USER_OPEN_IN_OUT, 0, 0);
  PostMessage(hwnd, WM_USER_DO_XCOPY, 0, 0);
     
  while (GetMessage(&msg, NULL, 0, 0)) {
    TranslateMessage(&msg);
    DispatchMessage(&msg);
  }
  return msg.wParam;
}

LRESULT CALLBACK wndProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
{
  switch (message) {
  case WM_CLOSE:
    break;

  case WM_CREATE:
    return 0;

  case WM_DESTROY:
    PostQuitMessage(0);
    return 0;

  case WM_NEXT_XCOPY:      
    if (initSocket() == 0) {
      _beginthread(thread, 0, NULL);
    }
    return 0;
  }
  return DefWindowProc(hwnd, message, wParam, lParam);
}
------------------------------------------------------------------------

Thank you, 73,

-- 
Don Kuenz KB7RPU
There was a young lady named Bright Whose speed was far faster than light;
She set out one day In a relative way And returned on the previous night.

[toc] | [prev] | [next] | [standalone]


#96175

From Arlen George Holder <arlinggeorgeholder@nospam.net>
Date2019-08-15 00:29 +0000
Message-ID<qj290v$c3e$1@news.mixmin.net>
In reply to#96169
On Thu, 15 Aug 2019 07:52:11 +1000, Peter Jason wrote:

> Is this the correct way to do it; should some entries be on the same
> line?

To share further information... this is often the first line:
 127.0.0.1 localhosts #loopback

As I recall, you can add two entries per line (but check me on that).

For example, instead of:
127.0.0.1 domain1.com 
127.0.0.1 domain2.com
You can do the following (as I recall):
127.0.0.1 domain1.com domain2.com
But most of the time two entries show up this way:
 192.168.1.10 foo.mydomain.org foo
 192.168.1.13 bar.mydomain.org bar
As documented here:
 <http://man7.org/linux/man-pages/man5/hosts.5.html>
So I'll let someone else expound on the two-entries per line value.

I'm not sure whether there is _any_ difference, but this works also:
 0.0.0.0  domain1.com

In addition, it's helpful to enable this easy edit to the hosts file:
 Start > Run > hosts <Enter>
Simply by adding the following app-paths key pointing to the hosts file:
 HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\hosts.exe
 Default = C:\windows\system32\drivers\etc\hosts
Where it's helpful to set up permissions to allow edits.
And where you set extensionless files to open in your favorite editor.
 *** cut here ***
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\.]
[HKEY_CLASSES_ROOT\.\shell]
[HKEY_CLASSES_ROOT\.\shell\open]
[HKEY_CLASSES_ROOT\.\shell\open\command]
@="\"C:\\Windows\\System32\\NOTEPAD.EXE\" \"%1\""

 *** cut here ***

In addition, the MVP hosts file is well maintained over the years.
<http://winhelp2002.mvps.org/hosts.htm>

Hope this helps as my contribution today to the Usenet potluck for this ng.
As always, please correct and expand upon this information so all benefit.

[toc] | [prev] | [next] | [standalone]


#96234

From"s|b" <me@privacy.invalid>
Date2019-08-15 18:29 +0200
Message-ID<grlfjlFk2msU1@mid.individual.net>
In reply to#96169
On Thu, 15 Aug 2019 07:52:11 +1000, Peter Jason wrote:

> Is this the correct way to do it; should some entries be on the same
> line?

For some time,

0.0.0.0

is used.

<http://winhelp2002.mvps.org/hosts.txt>

-- 
s|b

[toc] | [prev] | [next] | [standalone]


#96295

From"Carlos E.R." <robin_listas@es.invalid>
Date2019-08-16 12:12 +0200
Message-ID<a5ci2g-qho.ln1@Telcontar.valinor>
In reply to#96234
On 15/08/2019 18.29, s|b wrote:
> On Thu, 15 Aug 2019 07:52:11 +1000, Peter Jason wrote:
> 
>> Is this the correct way to do it; should some entries be on the same
>> line?
> 
> For some time,
> 
> 0.0.0.0

There are plans to use those IPs on Internet.

-- 
Cheers, Carlos.

[toc] | [prev] | [next] | [standalone]


#96275

FromPeter Jason <pj@jostle.com>
Date2019-08-16 11:36 +1000
Message-ID<2s1cletmmlsm7t1n4tqhud5a3q8depi9gt@4ax.com>
In reply to#96169
On Thu, 15 Aug 2019 07:52:11 +1000, Peter Jason <pj@jostle.com> wrote:

>I am using the hosts file to block unwanted Internet sites, and the
>following works so far. Win10 1903
>
>*******************************
># Copyright (c) 1993-2009 Microsoft Corp.
>#
># This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
>#
># This file contains the mappings of IP addresses to host names. Each
># entry should be kept on an individual line. The IP address should
># be placed in the first column followed by the corresponding host
>name.
># The IP address and the host name should be separated by at least one
># space.
>#
># Additionally, comments (such as these) may be inserted on individual
># lines or following the machine name denoted by a '#' symbol.
>#
># For example:
>#
>#      102.54.94.97     rhino.acme.com          # source server
>#       38.25.63.10     x.acme.com              # x client host
>
># localhost name resolution is handled within DNS itself.
>#	127.0.0.1       localhost
>#	::1             localhost
>
>127.0.0.1	www.expressvpn.com
>127.0.0.1	expressvpn.com
>127.0.0.1	www.ladbrokes.com.au
>127.0.0.1	ladbrokes.com.au
>127.0.0.1	www.get-express-vpn.com
>127.0.0.1	get-express-vpn.com
>127.0.0.1	www.drazens.com
>127.0.0.1	drazens.com
>127.0.0.1	www.nutaku.net
>127.0.0.1	nutaku.com
>127.0.0.1	www.trazens.com
>127.0.0.1	trazens.com
>127.0.0.1	www.velocecdn.com
>127.0.0.1	velocecdn.com
>
>***********************************************************
>
>Is this the correct way to do it; should some entries be on the same
>line?
>
>	


Thanks for the advice.

I have a copy of the Hosts file on the desktop into which I paste any
errant URL.  Then occasionally I copy this over to...
C:\Windows\System32\drivers\etc
to swap the Hosts file there.
So far this is working well.

The blocked sites just disappear, but one on them throws up a "can't
be reached" on a separate browser page.   Can this just be made to
disappear too?

[toc] | [prev] | [next] | [standalone]


#96288

FromPaul <nospam@needed.invalid>
Date2019-08-16 03:39 -0400
Message-ID<qj5mjt$ned$1@dont-email.me>
In reply to#96275
Peter Jason wrote:
> On Thu, 15 Aug 2019 07:52:11 +1000, Peter Jason <pj@jostle.com> wrote:
> 
>> I am using the hosts file to block unwanted Internet sites, and the
>> following works so far. Win10 1903
>>
>> *******************************
>> # Copyright (c) 1993-2009 Microsoft Corp.
>> #
>> # This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
>> #
>> # This file contains the mappings of IP addresses to host names. Each
>> # entry should be kept on an individual line. The IP address should
>> # be placed in the first column followed by the corresponding host
>> name.
>> # The IP address and the host name should be separated by at least one
>> # space.
>> #
>> # Additionally, comments (such as these) may be inserted on individual
>> # lines or following the machine name denoted by a '#' symbol.
>> #
>> # For example:
>> #
>> #      102.54.94.97     rhino.acme.com          # source server
>> #       38.25.63.10     x.acme.com              # x client host
>>
>> # localhost name resolution is handled within DNS itself.
>> #	127.0.0.1       localhost
>> #	::1             localhost
>>
>> 127.0.0.1	www.expressvpn.com
>> 127.0.0.1	expressvpn.com
>> 127.0.0.1	www.ladbrokes.com.au
>> 127.0.0.1	ladbrokes.com.au
>> 127.0.0.1	www.get-express-vpn.com
>> 127.0.0.1	get-express-vpn.com
>> 127.0.0.1	www.drazens.com
>> 127.0.0.1	drazens.com
>> 127.0.0.1	www.nutaku.net
>> 127.0.0.1	nutaku.com
>> 127.0.0.1	www.trazens.com
>> 127.0.0.1	trazens.com
>> 127.0.0.1	www.velocecdn.com
>> 127.0.0.1	velocecdn.com
>>
>> ***********************************************************
>>
>> Is this the correct way to do it; should some entries be on the same
>> line?
>>
>> 	
> 
> 
> Thanks for the advice.
> 
> I have a copy of the Hosts file on the desktop into which I paste any
> errant URL.  Then occasionally I copy this over to...
> C:\Windows\System32\drivers\etc
> to swap the Hosts file there.
> So far this is working well.
> 
> The blocked sites just disappear, but one on them throws up a "can't
> be reached" on a separate browser page.   Can this just be made to
> disappear too?

Doesn't the browser have a "Popup Blocker" tick box
for that in the preferences ? In 2019, that's probably
ticked by default.

    Paul

[toc] | [prev] | [next] | [standalone]


#96309

FromnotX <no.email@dummy.invalid>
Date2019-08-16 11:42 -0500
Message-ID<a2B5F.5$A81.1@fx15.iad>
In reply to#96288
On 8/16/19 2:39 AM, Paul wrote:

[snip]

> Doesn't the browser have a "Popup Blocker" tick box
> for that in the preferences ? In 2019, that's probably
> ticked by default.
> 
>     Paul

AFAIK, no junk (advertising, etc...) popups are affected by this, just 
the legitimate popups.

[toc] | [prev] | [next] | [standalone]


#96307

FromMikeS <MikeS@fred.com>
Date2019-08-16 17:39 +0100
Message-ID<qj6m8r$rkq$1@gioia.aioe.org>
In reply to#96275
On 16/08/2019 02:36, Peter Jason wrote:
> On Thu, 15 Aug 2019 07:52:11 +1000, Peter Jason <pj@jostle.com> wrote:
> 
>> I am using the hosts file to block unwanted Internet sites, and the
>> following works so far. Win10 1903
>>
>> *******************************
>> # Copyright (c) 1993-2009 Microsoft Corp.
>> #
>> # This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
>> #
>> # This file contains the mappings of IP addresses to host names. Each
>> # entry should be kept on an individual line. The IP address should
>> # be placed in the first column followed by the corresponding host
>> name.
>> # The IP address and the host name should be separated by at least one
>> # space.
>> #
>> # Additionally, comments (such as these) may be inserted on individual
>> # lines or following the machine name denoted by a '#' symbol.
>> #
>> # For example:
>> #
>> #      102.54.94.97     rhino.acme.com          # source server
>> #       38.25.63.10     x.acme.com              # x client host
>>
>> # localhost name resolution is handled within DNS itself.
>> #	127.0.0.1       localhost
>> #	::1             localhost
>>
>> 127.0.0.1	www.expressvpn.com
>> 127.0.0.1	expressvpn.com
>> 127.0.0.1	www.ladbrokes.com.au
>> 127.0.0.1	ladbrokes.com.au
>> 127.0.0.1	www.get-express-vpn.com
>> 127.0.0.1	get-express-vpn.com
>> 127.0.0.1	www.drazens.com
>> 127.0.0.1	drazens.com
>> 127.0.0.1	www.nutaku.net
>> 127.0.0.1	nutaku.com
>> 127.0.0.1	www.trazens.com
>> 127.0.0.1	trazens.com
>> 127.0.0.1	www.velocecdn.com
>> 127.0.0.1	velocecdn.com
>>
>> ***********************************************************
>>
>> Is this the correct way to do it; should some entries be on the same
>> line?
>>
>> 	
> 
> 
> Thanks for the advice.
> 
> I have a copy of the Hosts file on the desktop into which I paste any
> errant URL.  Then occasionally I copy this over to...
> C:\Windows\System32\drivers\etc
> to swap the Hosts file there.
> So far this is working well.
> 
> The blocked sites just disappear, but one on them throws up a "can't
> be reached" on a separate browser page.   Can this just be made to
> disappear too?
> 
Are you both aware that there are many adblocking hosts available on the 
Internet with comprehensive and regularly updated entries?

I use this one
https://github.com/StevenBlack/hosts
but many others are available.

[toc] | [prev] | [next] | [standalone]


#96318

FromRabid Robot <rabid@rob.ot>
Date2019-08-16 13:48 -0400
Message-ID<L%B5F.13485$6H5.3325@fx45.iad>
In reply to#96307
On 2019-08-16 12:39 p.m., MikeS wrote:
> On 16/08/2019 02:36, Peter Jason wrote:
>> On Thu, 15 Aug 2019 07:52:11 +1000, Peter Jason <pj@jostle.com> wrote:
>>
>>> I am using the hosts file to block unwanted Internet sites, and the
>>> following works so far. Win10 1903
>>>
>>> *******************************
>>> # Copyright (c) 1993-2009 Microsoft Corp.
>>> #
>>> # This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
>>> #
>>> # This file contains the mappings of IP addresses to host names. Each
>>> # entry should be kept on an individual line. The IP address should
>>> # be placed in the first column followed by the corresponding host
>>> name.
>>> # The IP address and the host name should be separated by at least one
>>> # space.
>>> #
>>> # Additionally, comments (such as these) may be inserted on individual
>>> # lines or following the machine name denoted by a '#' symbol.
>>> #
>>> # For example:
>>> #
>>> #      102.54.94.97     rhino.acme.com          # source server
>>> #       38.25.63.10     x.acme.com              # x client host
>>>
>>> # localhost name resolution is handled within DNS itself.
>>> #    127.0.0.1       localhost
>>> #    ::1             localhost
>>>
>>> 127.0.0.1    www.expressvpn.com
>>> 127.0.0.1    expressvpn.com
>>> 127.0.0.1    www.ladbrokes.com.au
>>> 127.0.0.1    ladbrokes.com.au
>>> 127.0.0.1    www.get-express-vpn.com
>>> 127.0.0.1    get-express-vpn.com
>>> 127.0.0.1    www.drazens.com
>>> 127.0.0.1    drazens.com
>>> 127.0.0.1    www.nutaku.net
>>> 127.0.0.1    nutaku.com
>>> 127.0.0.1    www.trazens.com
>>> 127.0.0.1    trazens.com
>>> 127.0.0.1    www.velocecdn.com
>>> 127.0.0.1    velocecdn.com
>>>
>>> ***********************************************************
>>>
>>> Is this the correct way to do it; should some entries be on the same
>>> line?
>>>
>>>     
>>
>>
>> Thanks for the advice.
>>
>> I have a copy of the Hosts file on the desktop into which I paste any
>> errant URL.  Then occasionally I copy this over to...
>> C:\Windows\System32\drivers\etc
>> to swap the Hosts file there.
>> So far this is working well.
>>
>> The blocked sites just disappear, but one on them throws up a "can't
>> be reached" on a separate browser page.   Can this just be made to
>> disappear too?
>>
> Are you both aware that there are many adblocking hosts available on the
> Internet with comprehensive and regularly updated entries?
> 
> I use this one
> https://github.com/StevenBlack/hosts
> but many others are available.

I can vouch for StevenBlack's lists. His fake news one is awful though;
it's completely biased.

[toc] | [prev] | [standalone]


Back to top | Article view | alt.comp.os.windows-10


csiph-web