4

I want to block access to a certain ip address via windows host.

This is the ip address 41.190.8.17. And this is the content of my host file.

# localhost name resolution is handle within DNS itself.

127.0.0.1 41.190.8.17

If I go to my browser and input 41.190.8.17, it takes me directly to the site.

Please can someone tell me why it is ignoring this?

| improve this question | | | | |
6

It won't work that way, because the hosts-file is only being used for name resolution via DNS. Since it is already an IP-Address, Windown (or you application) don't need to do a DNS Lookup.

I think you have to block taccess to the IP-Address in questing with the windows firewall. Maybe this would help, depends on what Windows Version you're using

| improve this answer | | | | |
  • How about if I want all requests to that IP Address reirected to my localhost? – Mob Nov 11 '12 at 14:45
  • 1
    I think you'll have to set it via the firewall as well. – Bonsi Scott Nov 11 '12 at 19:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.