Results 1 to 7 of 7
Hello guys,
I have several computers at home and I was trying to block off some websites by using
Code:
nano /etc/hosts
I tried to block one website and was ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 12-05-2009 #1
How to block using /etc/hosts for home network
Hello guys,
I have several computers at home and I was trying to block off some websites by using
I tried to block one website and was successful in doing so in my laptop. However, when I checked on our PC, the website can still be accessed.Code:nano /etc/hosts
I thought that since we are sharing one router to access the web, we therefore share the same ip address. So what I block in my laptop is also blocked in our home network. Now I realize that I am wrong.
Can somebody please be so kind to share how I may be able to do so? I mean to block websites without doing it one by one on all our PCs and lappys?
Thank you very much!Last edited by nujinini; 12-06-2009 at 01:31 AM. Reason: grammar :(
nujinini
Linux User #489667
- 12-06-2009 #2
What kind of router do you have?
If you have a linux router then it's easy, use iptables, if you don't know how, here it is a example:
iptables -A FORWARD -d IP_OF_WEB_SITE -j DROP
This was not tested so I may be wrong.
Another way is to install a proxy on your router and this way you will be able to block web sites from squid(if you will be using squid as a proxy).
- 12-07-2009 #3
Each computer you want to protect must have the entry in
its own hosts file. It does not block them from contacting
you but blocks you from contacting them, by the bogus
address you put in the hosts file, such as 127.0.0.1
- 12-08-2009 #4
most routers have the ability to block websites built in, you should just poke around the router configuration page, i'm sure its there
- 12-08-2009 #5
- 12-08-2009 #6
- 12-08-2009 #7
it should be a web page, every router runs a webserver, i don't know what router you have so I can't tell you and i'm not about to go and look it up even if I did know, it should be like 192.168.0.1 or 192.168.1.1


Reply With Quote

