Solved

Windows XP: Block IP Address

Posted on 2011-03-08
5
682 Views
Last Modified: 2012-05-11
I can block a website by a domain by making a host entry.

How can block a website by IP address?  Is there a file like the host file I can edit?  Is there any way to do this on Windows XP without using third-party software or hardware?
0
Comment
Question by:hankknight
5 Comments
 
LVL 17

Expert Comment

by:houssam_ballout
ID: 35074316
This is a good solution for you:

http://www1.k9webprotection.com/
0
 
LVL 8

Accepted Solution

by:
Acosta Technology Services earned 500 total points
ID: 35074355
Source:  www.internetfixes.com

If there are specific Web sites you want to prevent users from accessing, you could use Internet Explorer's Content Advisor or invest in a third-party solution to block access. But you can also block access to specific Web sites using the Route command to modify the route table.

When you type an Internet address into the browser, Windows XP uses the local route table as a network map to determine where to send the packet. In most cases, the route table directs the packet to the gateway, which then sends it out to the Internet.

However, you can configure the route table to send packets addressed to a certain Web site to a dead end. The result makes it appear as if the site doesn't exist.

To begin, you need the IP address of the Web site to which you want to block access. You also need an unassigned IP address within your local subnet that isn't in use by any computer or device.

For example, let's say that the IP address you want to block is 100.100.100.100, and an IP address on your local subnet that isn't in use is 192.168.100.51. Modify the route table with the following command:

Route -p add 100.100.100.100 mask 255.255.255.255 192.168.100.51
0
 
LVL 33

Expert Comment

by:Todd Gerbert
ID: 35074563
Been a while, but I think Windows XP with Service Pack 2 or later includes a firewall, which will definitely do what you're asking.

OpenDNS is a free 3rd party service that can control access to web sites: http://www.opendns.com/

Microsoft's Family Safety also does a decent job of filtering access to websites, and is free: http://www.microsoft.com/security/family-safety/default.aspx#Internet-use

If you wanted to block access to Google, for example, you could put 127.0.0.1 google.com www.google.com in the C:\Windows\system32\drivers\etc\hosts file - which will cause your computer to think google.com is it itself.
0
 
LVL 42

Expert Comment

by:David S.
ID: 35074652
Actually it seems you can use the hosts file to alias one IP address to another, just like you'd set the IP address associated with a domain name.

127.0.0.1  10.23.123.234

Open in new window

0
 
LVL 16

Author Comment

by:hankknight
ID: 35082209
Thank you all for your ideas.  As mentioned in the original post, third-party software is not an option.  Using Route works best for what I need.

0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
uploading CentOS to Azure (no root access) 3 69
ntdlr  is missing or corrupt 15 133
Decrypting the Zepto Virus 21 614
HP PC Hardware Diagnostics UEFI 11 118
Most of the time we are in fix when all of sudden our systems behave weirdly.  Such problems cost time and effort... so it's best to take some preventive actions so that we can avoid such issues or overcome such problems more easily. Preventive M…
We have adopted the strategy to use Computers in Student Labs as the bulletin boards. The same target can be achieved by using a Login Notice feature in Group policy but it’s not as attractive as graphical wallpapers with message which grabs the att…
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…
In this video I am going to show you how to back up and restore Office 365 mailboxes using CodeTwo Backup for Office 365. Learn more about the tool used in this video here: http://www.codetwo.com/backup-for-office-365/ (http://www.codetwo.com/ba…

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now