Score:0

Block domain and all of its paths, except for some

ua flag

Let's say I want to block access to ALL of reddit.com, except for www.reddit.com/r/memes (and its sub paths) and www.reddit.com/r/AskReddit (and its sub paths). This example could apply to any site and to any sub path.

I've tried adding 127.0.0.1 www.reddit.com to /etc/hosts, but then I couldn't allow specific sub paths.

Is there a way to allow only specific sub paths of a domain in my computer?

ru flag
Not with the hosts file. Hosts file operates on the *entire* domain, not sub-parts. If you want to do block levels on URIs and not hostnames you need application level filtering, not the hosts file.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.