/[a-zA-Z0-9]+\.[a-z]+\/.*(?:[!"#$%&'()*+,:;<=>?@/\^_`{|}~-]).*[a-zA-Z0-9]{4}/$third-party,xmlhttprequest,domain=~phncdn.com|pornhub.com|redtube.com|youporn.com
This rule makes no sense. The formatting with the $domain option explicitly binds this rule to function on pornhub.com|redtube.com|youporn.com. The domain flag, though the docs don't say so, can only logically function in a binary fashion. By specifying a domain exception ("~") followed by domain inclusion, the exception is redundant and irrelevant and should throw an error on parsing, because by applying the domain option with inclusion domains, you're automatically making all other domains an exception to this rule.
Can someone please confirm or deny if there is some sort of really bad logic in ABP itself that will actually accept this rule? Or does it the engine simply ignore the exception domain? Or worse yet, does the engine just, in a buggy way, eat up this rule and bug out by applying this filter to all domains except for phncdn.com? If I'm correct with my logic here, then the docs and the syntax should be updated to:
$~domain=
$domain=
Hope someone can shed some light or confirm my suspicions here. It's really difficult to contribute when you've got to unlearn everything you've ever learned about structure, syntax, order of operations and basic logic just to start to try to understand the filtering syntax in this engine.
In current easylist, this rule makes no sense
-
- Posts: 8
- Joined: Wed Dec 17, 2014 10:14 am
Re: In current easylist, this rule makes no sense
from en/filters#options
For example, domain=~example.com means that the filter should be applied on pages from any domain but "example.com" and domain=example.com|~foo.example.com restricts the filter to the "example.com" domain with the exception of "foo.example.com" subdomain.
Re: In current easylist, this rule makes no sense
see also en/filter-cheatsheet
domain= Specify a list of domains, separated by bar lines (|), on which a filter should be active. A filter may be prevented from being activated on a domain by preceding the domain name with a tilde (~).
domain= Specify a list of domains, separated by bar lines (|), on which a filter should be active. A filter may be prevented from being activated on a domain by preceding the domain name with a tilde (~).
-
- Posts: 8
- Joined: Wed Dec 17, 2014 10:14 am
Re: In current easylist, this rule makes no sense
Thanks maxp for the reply. I'm still confused though. From your quote:
Or does this mean that the filter stops functioning while within the subdomain? Sorry, the ambiguity of English > ambiguity of these rules.
So does this mean that the filter applies to both example.com and foo.example.com? Why wouldn't the filter simply be written as "$domain=example.com|foo.example.com"?and domain=example.com|~foo.example.com restricts the filter to the "example.com" domain with the exception of "foo.example.com" subdomain.
Or does this mean that the filter stops functioning while within the subdomain? Sorry, the ambiguity of English > ambiguity of these rules.

-
- Posts: 8
- Joined: Wed Dec 17, 2014 10:14 am
Re: In current easylist, this rule makes no sense
Right but still my question remains. example.com is not the same host as foo.example.com, so it seems redundant to specify the exception here. The filter is bound to example.com, so whilst on foo.example.com, the filter shouldn't (by what I can see) trigger anyway.mapx wrote:see also en/filter-cheatsheet
domain= Specify a list of domains, separated by bar lines (|), on which a filter should be active. A filter may be prevented from being activated on a domain by preceding the domain name with a tilde (~).
Re: In current easylist, this rule makes no sense
back to your question
domain=~phncdn.com|pornhub.com|redtube.com|youporn.com
indeed ~phncdn.com makes no sense here
it is useful only when you want to exclude a subdomain
domain=~sub.pornhub.com|pornhub.com|redtube.com|youporn.com
domain=~phncdn.com|pornhub.com|redtube.com|youporn.com
indeed ~phncdn.com makes no sense here
it is useful only when you want to exclude a subdomain
domain=~sub.pornhub.com|pornhub.com|redtube.com|youporn.com
-
- Posts: 8
- Joined: Wed Dec 17, 2014 10:14 am
Re: In current easylist, this rule makes no sense
Thanks for the response. I thought I scarred you off.mapx wrote:back to your question
domain=~phncdn.com|pornhub.com|redtube.com|youporn.com
indeed ~phncdn.com makes no sense here
it is useful only when you want to exclude a subdomain
domain=~sub.pornhub.com|pornhub.com|redtube.com|youporn.com

Re: In current easylist, this rule makes no sense
moderator.
Anyway I posted on easylist forum about your question
https://forums.lanik.us/viewtopic.php?f=64&t=21950
Anyway I posted on easylist forum about your question
https://forums.lanik.us/viewtopic.php?f=64&t=21950