How to block myself from the hosts file?

10,376

Solution 1

You could try Folder Guard and ask someone to password protect the directory with a strong password that could resist anybody's temptation to crack it:

http://folder-guard.en.softonic.com/

However, you could still use proxies to access those sites. Try your will first, that is by far the most efficient way to stop you from visiting sites you don't really want to spend time on.

Solution 2

I'm quite sure you can do that by accessing the file properties' Security tab, and changing the permissions for either Administrators or your account.

Right click -> Properties -> Security -> Modify

Edit: You can also make it a hidden file and hide hidden files from the control panel, or a read-only file.

Adding steps like that that you need to go through to access your evil pastimes usually adds warning steps for you to tell yourself "No!" before you succumb to the temptation and it's too late. Just like, with some people, locking their computer and putting the key high up, stuck on the ceiling's fan or something, is all it takes to combat their computer addiction.

And in the same way that the best way to stop smoking is to throw away every cigarette, ashtray, lighter and other tobacco furnitures every time you decide to stop. Then to start again you need to spend a lot and take the time to go to the store. The more work it is to succumb, the least you'll do it.

Alternatively, software like those on this page can help, more user-friendily.

http://alternativeto.net/software/selfcontrol/

They just won't allow you to visit the websites if you ask them to, no matter what.

I feel for you. I have a lot of such issues, one of which is this website. xD

(Look at time since subscription, number of posts and such stats. Hmm. Problem.)

Solution 3

I have a fix you can try. Create for yourself a new user account with 'Administrator group' permissions. Then log back in as the original Administrator. View the folder properties of the windows\system32\drivers\etc folder and change the access priviledges to FULL CONTROL for the Administrator, ALLOW read for new user account, DENY all other functions for the new user account.

Now get a trusted friend to login to the Adminstrator account and change the password to something difficult (have him write it down and keep it) while not in your presence. Then logout. Instruct your friend to never give you the password unless he is with you in person. Chances are you will never need your friend to login again. If you are really sensitive about the matter this can all be accomplished without ever explaining why.

From then on you use the new user account having full administrative priviledges, but are denied the ability to change the HOSTS file and it's parent folder.

Solution 4

From an administrator account, ACL your hosts file to deny yourself all access.

cacls C:\windows\system32\drivers\etc\HOSTS /E /D userid

Solution 5

How often do you actually need to make use of your administrative privileges?

Why not set yourself up with an account with fewer privileges and only use the admin account when you actually need those admin powers? Set up the admin account with a ridiculously hard to remember password (long and random). Write the password down, and then put that password behind lock and key (a safe?). Even better would be to give the password to a trusted friend and make the friend read you the password over the phone on the occasions you need admin rights.

If this is a self-control issue, the idea is to make the effort of overcoming your web-site block sufficient that you will catch yourself and resist temptation before you go through the process of getting your admin password, etc.

Of course, there's also commercial software out there specifically for blocking access to portions of the Web, and it is usually something where it makes sense to make someone else have the password that controls the blocking software.

Share:
10,376

Related videos on Youtube

Admin
Author by

Admin

Updated on September 18, 2022

Comments

  • Admin
    Admin almost 2 years

    Basically I'm trying to have an account where I can do everything an administrator can do, except I don't want to be able to access or modified my hosts file ( for personal reason, i'm trying to stop myself from visiting certain sites, but I need to be able to install stuff on my computer) is that possible? I tried every software like k9 or filters like opendsn, but they are too easy to bypass. I'm using windows 7 x86 ultimate edition.

  • OCDtech
    OCDtech over 11 years
    you can do all this with 'cacls' after your friend changes the Administrator password. Same effect.
  • allquixotic
    allquixotic over 11 years
    Yeah. Also you could do a DNS query on the site and type in its IP address, or use a different computer/operating system, or look at it through google images or google translate, etc.
  • Big McLargeHuge
    Big McLargeHuge over 11 years
    I don't get it... couldn't you just change it back?
  • Big McLargeHuge
    Big McLargeHuge over 11 years
    I wish you were were right, but unfortunately that's just not the case. I can verify that if you remove the "Change permissions" and even "Take ownership" permissions from another administrator, they can still do those things easily.