Script to check if a URL matches any rule in easylist

General information, announcements and questions about the EasyList subscriptions.
Locked
VekkioKonio
New Member
New Member
Posts: 2
Joined: Fri May 09, 2014 10:28 am

Script to check if a URL matches any rule in easylist

Post by VekkioKonio »

Good morning,

I have checked in this section of the forum, but I have not found any answer to my problem. My problem is the following: I have some URLs and I want to check if these are trackers/ads/... Is there any bash/python script doing this work? Basically I need somehow the AdBlock behaviour, with a script allowing to verify if the URL matches any rule present in Easylist.

Any help would be great, thank you in advance.
User avatar
Crits
Liste FR Author
Liste FR Author
Posts: 682
Joined: Sun Dec 18, 2011 6:21 pm
Location: France

Post by Crits »

There is a manual way to do that using Adblock Plus for Firefox.

The setup:
1. Embed your URLs using HTML tags. You can use the <img> tag even if you want to test URLs that point to scripts (so that you are sure not to execute them).
For example:

Code: Select all

<img src="http://www.google-analytics.com/ga.js"></img>
<img src="http://ww690.smartadserver.com/call2/"></img>
2. Paste them into an HTML file

3. Open the file with Firefox, open the blockable item list (Ctrl+Maj+V), sort them by "Filter"

4. All the URLs in red are being filtered, all the others are not.
While they are sorted this way, you may want to select them all and paste them elsewhere (the URL, and not the filters, will be pasted, as wanted).


I think the javascript responsible for this in ABP is in matcher.js, but I don't want to dig deeper into that myself.
VekkioKonio
New Member
New Member
Posts: 2
Joined: Fri May 09, 2014 10:28 am

Post by VekkioKonio »

Thank you for your answer! It is exactly what I was looking for!
Locked