3

I recently got a new router, a DRL-600L Router from D-Link, and was setting up some filters to block out certain websites. One problem I am having is blocking out addresses that use https instead of http.

For example, I'm trying to block out Facebook, because Facebook. So far, the filter filters http://www.facebook.com perfectly fine, but for the url https://www.facebook.com, it won't block that.

How can I block those kinds of websites?

4 Answers 4

7

You can point your router to opendns.com and setup a free account and block anything you want. Unfortunately Dlink does not give you an easy way to do this, hence going to opendns.com.

2

I'm assuming it's a DIR-600L router, and that you're using the built-in parental control feature. If it doesn't work using https, then this router doesn't support filtering https based on domain name. This is more difficult to do, especially since some browsers do not send the domain name before establishing a secure connection, at which point the traffic is encrypted and the router can't filter anymore.

You can use the firewall to block Facebook's know IP addresses, though you should be aware that they may change at any time. If the router supports IPv6 and you have an IPv6 prefix assigned by your ISP, don't forget to filter Facebook's IPv6 addresses. A quick search will give you a list of IP addresses used by Facebook.

0
2

I found an easier wasy of doing this using the Windows hosts file.

Open the hosts file in Notepad, from the location C:\Windows\System32\drivers\etc
Add the following lines after the last line. Do not add http or https

127.0.0.1          www.facebook.com
1

An https URL block is not supported except in some newer models in routers. You can block these URLs using your hosts file.

Steps:

  1. Open the hosts file in Notepad form the location C:\Windows\System32\drivers\etc

  2. Add the following line after the last line

    127.0.0.1          www.facebook.com facebook.com
    

Result: It blocks the URL assuming the given address is from the local machine itself.

2
  • 2
    The https:// or http:// parts are wrong here. The file contains a mapping from IP addresses to host names, not URLs. (Also, multiple hosts with the same IP address usually go on the same line.)
    – tripleee
    Nov 20, 2016 at 18:53
  • 1
    The host file should contains hostnames not urls.
    – DavidPostill
    Nov 20, 2016 at 20:38

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .