el1t / uBlock-Safari

uBlock Origin - An efficient blocker for Chromium, Firefox, and Safari. Fast and lean.
GNU General Public License v3.0
2.75k stars 97 forks source link

Content Blocker #18

Open Baccount opened 7 years ago

Baccount commented 7 years ago

Read first: https://github.com/gorhill/uBlock/blob/master/CONTRIBUTING.md

Will Safari content blocker support be added?

Information on content blocker https://webkit.org/blog/3476/content-blockers-first-look/

el1t commented 7 years ago

Not likely, content blockers suffer some limitations as articulated by JS Blocker:

Safari has a new feature called "Content Blockers" that allows for extremely efficient resource blocking on both the desktop and iOS version of Safari. As much as I'd like to incorporate this into JS Blocker, it is not feasible to do so. Using a content blocker will prevent JS Blocker from showing you exactly what's going on on a website (i.e. you won't see what's allowed or blocked.) It'll also break all of JS Blocker's "other" features, such as showing alerts within the webpage and canvas fingerprinting protection. Besides the loss of features, content blockers are limited to 50,000 rules. While this seems like a high number, it isn't enough for efficient protection and a lot of rules would need to be cut out to even run a content blocker. Until Apple eases the restrictions (or at least raises the number of rules that can be in a content blocker), JS Blocker will not be using this API.

TheNewDarkOne commented 7 years ago

Yeah safari content blocking is near useless. Internet sadly needs a hell of a lot more than 50000 filters . heck I use 130k plus and still have to add more sometimes.

I remember when only thing you needed was a basic popup blocker back in day.

aaroncrespo commented 7 years ago

@el1t have @infernoboy or you opened radars with apple about these limitations? I think if 50,000 rules is too small a limit for high quality blocking that would be an easy fix for apple to raise (if they wanted) but they would only do that if they knew about it (as well as the other issues)

username1290 commented 7 years ago

a hosts file to act as a base would be useful for this

aaroncrespo commented 7 years ago

I dont think extensions can modify a hosts file. Modifying them doesn't sound like a very good user experience.

username1290 commented 7 years ago

One of the first things I do on a new computer is add a the MVPS hosts file: http://winhelp2002.mvps.org/hosts.htm

Fortunately it's also inside uBlocker, so it can be used on relatives' gadgets :)