How do I block porn completely on my Mac?

Hi Kim,

For any user you want to control (I would guess it's for other users on your Macs?), you could e.g.

- For (mostly) children: use the parental controls that come with Mac OS X (search in System Preferences). Make a list of pre approved sites, and all the new sites will have to be approved by you, who use the administrator account. Your children/other users with restricted access use a restricted account, and can't bypass the limitations e.g. by installing another browser.
Note: the built-in controls are for Safari. So if you have other browsers installed, and allow the users to access those browsers, they can browse whatever they want. So allow the users to only access Safari as a browser

- for any user: use the hosts file.
To add addresses to blocked sites list in hosts file, see
http://www.mactricksandtips.com/2009/07/using-hosts-file-to-block-web-access.html
http://osxdaily.com/2007/03/19/block-access-to-specified-sites-by-modifying-etchosts/
http://someonewhocares.org/hosts/ this site has a long list of sites you probably would want to add to your hosts file.

- also, for any user: It's YOUR computer, so only you should have access to the Administrator user. For anyone else, it's their restricted account or guest access. That way no one can install weird apps - even if there aren't really any porn apps per se on Mac, it's just the best practice. And even for yourself, it's not a bad practice to use a different account from the administrator account for daily tasks, and only use that for authentication when necessary.

The hosts file solution limits EVERY account on the computer, even if they all were administrators. (But it's your computer, so there is no reason to add more administrator users than yourself. That would just be bad karma).

I'm sure there are some apps for this... but the combination of hosts file modification and if you want extra controls, restricted access users (even for the spouse if needed) give you everything you need to achieve this goal.

And of course, make sure if there are multiple users on the computer (if there are multiple people using that computer, there should be multiple user accounts) that when the system is put to or waken from sleep, the screensaver with user login is on. Otherwise, if your user was logged in, someone else could use your account. That would not be bad karma for the porn but in general whenever there's a possibility people that shouldn't be close to your computer might access your account (email, chat, browser, some work app, you name it).
 
A word of warning: Apple seems to have badly broken the hosts file functionality in Snow Leopard (and I believe it remains broken in Lion as well, although I haven't tested it). Adding a lot of entries to your hosts file will cause extremely high CPU usage by a system process called DirectoryService. It is therefore not practical to use the hosts file to block a significant number of sites. For a dozen or so it's fine, but we're talking about tens of thousands, which would make your computer virtually unusable. I tried this just a week ago and was shocked, since this is the oldest method in the book and works well on every other Unix-like OS.

See this thread for more information and suggestions for alternate methods (warning: the alternate methods are for advanced users only): http://hints.macworld.com/article.php?story=20100713190059936

Perhaps a simpler way would be to use a DNS server which provides filtering. If you sign up for a free account at OpenDNS, you can use their pre-configured filter lists. They include a list for adult content.
 
Yes, agreed, opendns is a good way to do what you require. check the privacy statement from them before you do, though.
 
Back
Top