URL / IP blocking in Win2K ?

Is there a way to block access to certain URL's & IP adresses in Win2K by foraging in the registry or something? I want to use this techique to block against adservers ect. . I don't want to install 3rd party programs and stuff if it can be done mauallly in 2K.

Customization Tweaking 1789 This topic was started by ,


data/avatar/default/avatar13.webp

137 Posts
Location -
Joined 2001-07-26
Is there a way to block access to certain URL's & IP adresses in Win2K by foraging in the registry or something?
 
I want to use this techique to block against adservers ect..
I don't want to install 3rd party programs and stuff if it can be done mauallly in 2K.
 
I heard it can be done in XP somehow, but how do i do it in Win2K?
Oh.. if you know, for that matter is it possible in NT4?
 
Win2K SP2, IE5.5 SP2,
NT4, IE6
 
Cheers,

Participate on our website and join the conversation

You have already an account on our website? Use the link below to login.
Login
Create a new user account. Registration is free and takes only a few seconds.
Register
This topic is archived. New comments cannot be posted and votes cannot be cast.

Responses to this topic


data/avatar/default/avatar19.webp

3857 Posts
Location -
Joined 2000-03-29
Go to %windir%\system32\drivers\etc and open the "hosts" file in notepad. Then, just put in the domain names that you want to "block" and the IP that you want the requests to go to (like 127.0.0.1). The hosts file will be scanned first before your DNS servers, so anything listed on here will be resolved from this file rather than an outside source. To test this, enter your domain name and IP that you want to block, and then bring up the command prompt. From there, type "ipconfig /flushdns" and that will flush out any DNS mappings that are already in the localhost. Then, ping the domain name that you listed.

data/avatar/default/avatar13.webp

137 Posts
Location -
Joined 2001-07-26
OP
This sounds just like what i was after, thanks..
 
However i am not quite with you in configuring this file, and i just realised that i am not sure how to get the IP adress for a specific URL.
 
Say i want to block anything and everything at the domain www.yahoo.com , including www.yahoo.com/subcategories/
 
What would be the snippet of text i would put in the hosts file?
 
Thanks heaps Clutch,
Cheers.

data/avatar/default/avatar13.webp

137 Posts
Location -
Joined 2001-07-26
OP
Quote:# Copyright :copyright: 1993-1999 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

127.0.0.1 localhost
-- Removed examples --

Is this a valid configuration of the hosts file?
Any tips on how this would affect browsing the net would be greatly appreciated,
Thanks Guys.

Cheers,

data/avatar/default/avatar19.webp

3857 Posts
Location -
Joined 2000-03-29
Well, I am not sure about the geocities one with the slash in it, but other than that it looks fine. As for browsing, it *should* speed it up a slight amount as your system will not only be saved the time of resolving those network names, but it will also save the system time in downloading anything from those sites.

data/avatar/default/avatar13.webp

137 Posts
Location -
Joined 2001-07-26
OP
Thanks,
 
I find tis really neat:D
 
Funny i have never heard of this before or seen utilities or plugins which tweak this file for blocking.
 
Cheers,