问题
How Adblockplus uses https://easylist-downloads.adblockplus.org/easylist.txt to detect a url is an AD url? The regexes mentioned in this file contains '#' which does not seem to be a legit regex character. Can anyone point me to the code (https://github.com/adblockplus/adblockplus/tree/master/lib) where ADblock plus uses the list to categorize a url.
回答1:
Finally I found how AdblockPlus uses the easylist subscription rules to remove adverts from English webpages, including unwanted frames, images and objects. There are three kinds of rules namely -
- Blocking rules - Set of rules that determine addresses that Adblock Plus should block
- Exception rules - Exception rules are built the same as blocking rules, they define which addresses should be allowed even if matching blocking rules exists.
- Element hiding - Used to hide DOM elements on the page that are potential ADs. These rules are valid CSS selectors.
If anyone is planning to use / customize ADBlockPlus plugin then these set of rules will come handy because it covers most of the known advert urls till date.
来源:https://stackoverflow.com/questions/27334461/list-of-ad-urls-in-easylist