Microsoft Windows Vista Community Forums - Vistaheads
Recommended Download



Welcome to the Microsoft Windows Vista Community Forums - Vistaheads, YOUR Largest Resource for Windows Vista related information.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so , join our community today!

If you have any problems with the registration process or your account login, please contact us.

Driver Scanner

How to block IPs with 'route.exe' in Vista

microsoft.public.windows.vista.networking sharing






Speedup My PC
Reply
  #1 (permalink)  
Old 02-24-2008
Robert Weiss
 

Posts: n/a
How to block IPs with 'route.exe' in Vista
Hallo,
let's say i want to block www.disney.com (199.181.132.250). For that, i
enter following command into the shell:

route add 199.181.132.250 192.168.1.254

Subnet is 192.168.1.0/24
192.168.1.254 is unused

In XP the ip and dns is unreachable by browser now. Thats fine. But in vista
the same procedure doesn't work. It seems there's just an additional short
lag and then the site appears anyway. My guess is vista falls back to a
valid route after sensing the invalid route but i don't know for sure.

So, does anyone know how to use the 'route' command correctly on vista to
get the same result as in XP?


Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 02-24-2008
Chuck [MVP]
 

Posts: n/a
Re: How to block IPs with 'route.exe' in Vista
On Sun, 24 Feb 2008 02:12:35 +0100, "Robert Weiss" <no@email.com> wrote:

>Hallo,
>let's say i want to block www.disney.com (199.181.132.250). For that, i
>enter following command into the shell:
>
>route add 199.181.132.250 192.168.1.254
>
>Subnet is 192.168.1.0/24
>192.168.1.254 is unused
>
>In XP the ip and dns is unreachable by browser now. Thats fine. But in vista
>the same procedure doesn't work. It seems there's just an additional short
>lag and then the site appears anyway. My guess is vista falls back to a
>valid route after sensing the invalid route but i don't know for sure.
>
>So, does anyone know how to use the 'route' command correctly on vista to
>get the same result as in XP?


Robert,

When you set this up, do a "route print". Then do a second "route print" after
you try accessing the target web site. Let's see if Vista is changing the route
table.

Just for curiosity, why aren't you using the Hosts file?
<http://nitecruzr.blogspot.com/2006/06/bad-websites-dont-go-there.html>
http://nitecruzr.blogspot.com/2006/0...-go-there.html

--
Cheers,
Chuck, MS-MVP 2005-2007 [Windows - Networking]
http://nitecruzr.blogspot.com/
Paranoia is not a problem, when it's a normal response from experience.
My email is AT DOT
actual address pchuck mvps org.
Reply With Quote
  #3 (permalink)  
Old 02-24-2008
Seth
 

Posts: n/a
Re: How to block IPs with 'route.exe' in Vista
"Robert Weiss" <no@email.com> wrote in message
news:uJ3yTJodIHA.4140@TK2MSFTNGP04.phx.gbl...
> Hallo,
> let's say i want to block www.disney.com (199.181.132.250). For that, i
> enter following command into the shell:
>
> route add 199.181.132.250 192.168.1.254
>
> Subnet is 192.168.1.0/24
> 192.168.1.254 is unused
>
> In XP the ip and dns is unreachable by browser now. Thats fine. But in
> vista the same procedure doesn't work. It seems there's just an additional
> short lag and then the site appears anyway. My guess is vista falls back
> to a valid route after sensing the invalid route but i don't know for
> sure.
>
> So, does anyone know how to use the 'route' command correctly on vista to
> get the same result as in XP?


I'd sooner block the site by name in the HOSTS file. The IP could change
for whatever reason meaning your false route wouldn't be effective. Set the
record in the local HOSTS file something like...

127.0.0.1 www.disney.com

and the machine will never even attempt to look up the address and give an
immediate failure.

If you want to get fancy, setup a local webserver and point all the
"blocked" sites IPs there with an message saying this site is blocked.


Reply With Quote
  #4 (permalink)  
Old 02-24-2008
Robert Weiss
 

Posts: n/a
Re: How to block IPs with 'route.exe' in Vista
> I'd sooner block the site by name in the HOSTS file. The IP could change
> for whatever reason meaning your false route wouldn't be effective. Set
> the record in the local HOSTS file something like...


I'm aware of the HOSTS file but unfortunately the destination address
doesn't have a dns thus i'm trying to find a way to block ip addresses
otherwise (and without personal firewall or vista firewall).


Reply With Quote
  #5 (permalink)  
Old 02-24-2008
Robert Weiss
 

Posts: n/a
Re: How to block IPs with 'route.exe' in Vista
> Robert,
>
> When you set this up, do a "route print". Then do a second "route print"
> after
> you try accessing the target web site. Let's see if Vista is changing the
> route
> table.
>
> Just for curiosity, why aren't you using the Hosts file?
> <http://nitecruzr.blogspot.com/2006/06/bad-websites-dont-go-there.html>
> http://nitecruzr.blogspot.com/2006/0...-go-there.html


The IP doesn't have any dns entry.
I'll check the routing table once i'm back on the vista machine but i think
there will be no other entries. As a permanent route (route -p add) it has a
merit of 1 if i remember correctly and in the upper main table it shows a
merit of 21 i think that i couldn't lower any further. Maybe a traceroute
shows something. Will try that as well.


Reply With Quote
  #6 (permalink)  
Old 02-24-2008
Seth
 

Posts: n/a
Re: How to block IPs with 'route.exe' in Vista
"Robert Weiss" <no@email.com> wrote in message
news:O$vz$xpdIHA.544@TK2MSFTNGP05.phx.gbl...
>> I'd sooner block the site by name in the HOSTS file. The IP could change
>> for whatever reason meaning your false route wouldn't be effective. Set
>> the record in the local HOSTS file something like...

>
> I'm aware of the HOSTS file but unfortunately the destination address
> doesn't have a dns thus i'm trying to find a way to block ip addresses
> otherwise (and without personal firewall or vista firewall).


If it doesn't have a DNS registration, then how are you resolving
www.disney.com=199.181.132.250?

If it can be found on the Internet by name, then it has a DNS registration.
By using the HOSTS file, you are ignoring the DNS registration and forcing a
specific address be used.

Reply With Quote
  #7 (permalink)  
Old 02-25-2008
Robert Weiss
 

Posts: n/a
Re: How to block IPs with 'route.exe' in Vista
> If it doesn't have a DNS registration, then how are you resolving
> www.disney.com=199.181.132.250?
>
> If it can be found on the Internet by name, then it has a DNS
> registration. By using the HOSTS file, you are ignoring the DNS
> registration and forcing a specific address be used.


Disney (or http) was just an example. The point is to block IPs not DNS and
why Vista behaves differently (as XP) and how to fix that.


Reply With Quote
  #8 (permalink)  
Old 03-02-2008
Robert Weiss
 

Posts: n/a
Re: How to block IPs with 'route.exe' in Vista
I think i've got the solution...
XP accepts all target IPs (from local subnet) and routes blindly (thus
blocks) whereas Vista strictly needs a valid target IP (your own local IP
for example). If its invalid (no connection), vista will (most likely) fall
back to the next valid route to fix that.

Just a guess but at least it works. :-)


Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
tracing the route (with tracert) does not work any more with VISTA Paul (Bornival) microsoft.public.windows.vista.networking sharing 9 07-17-2008 21:41
route add in vista Christian Krüsi microsoft.public.de.windows.vista.netzwerk 8 08-23-2007 08:44
route add vista Christian Krüsi microsoft.public.windows.vista.networking sharing 0 08-14-2007 09:55
route add unter vista Christian Krüsi microsoft.public.de.windows.vista.administration 0 08-13-2007 14:58
route add command problem on vista bussiness Erkan GÖCEN microsoft.public.windows.vista.administration accounts passwords 1 06-14-2007 16:36




All times are GMT +1. The time now is 20:17.




Driver Scanner - Free Scan Now

Vistaheads.com is part of the Heads Network. See also XPHeads.com , Win7Heads.com and Win8Heads.com.


Design by Vjacheslav Trushkin for phpBBStyles.com.
Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.6.0 RC 2

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120