First of all, I couldn't find an appropriate section of the site to post this, so I just went with my beloved C++ section. Here is a request from a friend of mine. i am not sure how that can be possible. He wants me to write him an application that would block a website and the only way to unblock it should be by rebooting.
I thought about writing something that would modify the hosts file. If the user runs the application, it will add the target website to the hosts file and each time the machine is restarted the line for for the target website will be removed from the hosts file. The problem with this method is that the user still can manually alter the hosts file after running the application to unblock the website.
Any thoughts on how this problem can be solved?
2 Replies - 692 Views - Last Post: 18 January 2012 - 02:56 PM
Topic Sponsor:
#1
Filter a website without modifying the HOSTS file
Posted 18 January 2012 - 10:11 AM
Replies To: Filter a website without modifying the HOSTS file
#2
Re: Filter a website without modifying the HOSTS file
Posted 18 January 2012 - 12:01 PM
I really don't think C/C++ would be the appropriate language to do this job. I think the Software Development forum might yield better responses.
Jim
Jim
#3
Re: Filter a website without modifying the HOSTS file
Posted 18 January 2012 - 02:56 PM
I think a truly impenetrable filter needs to drop TCP packets or find a way for the system not to respond to them, which isn't a trivial task. Your code needs to operate within (or access) code in the TCP/IP layers. There's a lot of information on doing so. There are some Windows drivers that make this task much easier.
This post has been edited by blackcompe: 18 January 2012 - 02:59 PM
Page 1 of 1
|
|

New Topic/Question
Reply



MultiQuote




|