el1t / uBlock-Safari

uBlock Origin - An efficient blocker for Chromium, Firefox, and Safari. Fast and lean.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Explanation of the state of uBlock Origin (and other blockers) for Safari

opened this issue · comments

Very quick tl;dr: uBO will no longer work with Safari, use Firefox or a new "content blocker" app (see below for good replacements).

In the past few months, and especially in the past week, there have been a lot of posts and comments questioning the status of uBlock Origin for Safari. This should answer all questions on the status of uBO for safari.

uBlock Origin was ported for Safari in 2016, and was updated regulary (mostly changes from the main project) until 2018 when development completley stopped. Since then Apple has begun phasing out Safari extensions as extensions, and has instead been implenting a new extensions framework which is extremley limited in adblocking functions, only allowing "content blockers", which are just links bundled as an app which Safari enforces. From Safari 12 / macOS Mojave, old legacy Safari extensions were still allowed, but came with warnings saying that they will slow down your browsing (they infact won't, or at least not noticably). Safari also recently shut their Extension Gallery, instead redirecting it to the mac app store. Though it is still curently possible to install uBlock Origin by downloading the extension from Github (edit: must follow these instructions, it will not be starting from Safari 13 / macOS Catalina, when the legacy entension API will be fully deprecated.

It will not possible for uBlock Origin to work with the upcoming Safari 13 / macOS Catalina release
If you are a current user of uBlock Origin for Safari here are the options to continue blocking ads:

  1. For the moment continue to use Safari 12 with uBlockOrigin. Anybody with uBO currently installed, it won't be removed until you update to Safari 13. If you don't have uBO installed, and wish to install on a pre-Catalina version of Safari, Download the latest (and final) release here and follow these instructions to install it. Unfortunately it's a bit complicated. This will stop working with macOS Catalina (coming "this fall"). Update: It appears that it is not possible to install uBO permanently, it will always uninstall on a restart of Safari. If you have it, it should stay.
  2. Switch to a different browser. If you choose this, I strongly recomend Firefox. Chrome will itself be ending support for uBlockOrigin soon. If battery life is an issue for you get Firefox Beta, Nightly or Developer which has massive battery life improvements to bring it on par with Safari / Chrome being tested (note: somewhat unstable). This will come to the stable version, hopefully in time for uBO-Safari's eol.
  3. Get a content blocker. Not nearly as powerful as uBO, but the best option if you want to stay with Safari. Do not get the app called "uBlock", this is unassociated with uBlockOrigin (read about the split here), and is simply a content blocker with a big negative feature of having acceptable ads built in (which is AdBlockPlus's pay-to-play ad and tracker unblocking program). It shares no code with uBO and has no advantages over any other content blocking app. Here are some recomendations of content blockers:

Top picks

  • Adguard for Safari, very good blocking and free. Very customisable. Doesnt always have the best performance (though this has apparently been fixed). AdGuard's performance is quite controversial, read discussion [here].(#158 (comment)). AdGuard also uses the same lists and filter syntax as uBO, making migration easier.
    - 1Blocker, by far the most powerful, with custom rules and an element picker. This is the best option if you don't mind paying. Costs $10. Update: do not buy. 1Blocker has teased 1BlockerX for Mac, which will be a paid upgrade. I cannot reccomend buying an app now which will soon be obsolete.. Update 2: 1Blocker has said that it will be a free upgrade to 1BlockerX from the current version, so there isn't any reason to wait if you want it. 1Blocker has switched to a subscription model, even for people who already paid for it. Avoid.
  • Ka-block. Unexceptional. Free. Will block ads, nothing more. Pretty sure it's just a wrapper for easylist, but it's a good option if you mind paying for 1Blocker. Also open-source.

Other Good Options

  • Ghostery Lite. Free. Ghostery. Some advanced options for whitelisting. Good lists for ad and tracker blocking.
  • Adguard for Mac. Fully featured system wide adblocker, contains custom lists and element picker. Does cost after a trial, see here for prices.
  • Wipr. $1.99, simple featureless and popular. Don't see any advantage in this over Ka-block (see above) for an extra $1.99. Apparently Ka-Block doesn't work for youtube (wipr does), and Wipr uses 3 extensions to get around the limit in rules.

Do Not Reccomend

  • AdBlock Plus for Safari - Supports acceptable ads, a pay-to-play ad allowing system which allows certain ads and trackers which meet guidelines and pay AdBlock Plus. Some of these ads, imo, are not acceptable, and I don't consider any trackers acceptable. Uses Easylist so otherwise is identical to Ka-Block!.
  • uBlock - Don't at all associated with uBO or the code which uBO contains. Is instead identical to AdBlock Plus in all but name including acceptable ads.
  • AdBlock for Safari (made by BETAFISH INC) - Yet another acceptable ads-supporting blocker which just uses easylist. Avoid.
  • There are plenty more on the mac app store, have a look if none of these suit. No new content blockers can spy on you as they send lists though Safari's built in system, so they are all pretty safe. If you find a good one comment and I'll add it to this list.

Update: Here is a statement from gorhill (uBO developer) on the state of Safari

Edit: a lot people are asking about uBlock Origin not working in the future on Chrome. If you'd like more information on this, here is an article from ghacks from january, and a statement from gorhill, developer of uBlock.**

There has been discussion of this on Reddit Github and Hacker News.

commented

What differentiates an "ad-blocker" from a "content-blocker" that makes it impossible for this change? Isn't an "ad-blocker" just a "content-blocker" that only blocks a very specific type of content?

thanks for u summation. it's so sad:( i have used it for three years and it's time to say goodbye...

What differentiates an "ad-blocker" from a "content-blocker" that makes it impossible for this change? Isn't an "ad-blocker" just a "content-blocker" that only blocks a very specific type of content?

I must admit the the terminology isn't very clear. A Safari "content-blocker" app sends a list to Safari, and Safari blocks it. A regular blocker (like uBO) blocks content itself. Safari content blockers aren't all bad, they are more secure in that they can't possibly collect your browsing history (not that uBO does), but lack the level of customisation and power that a regular blocker like uBO can provide.

Thanks! You should pin this issue.

Thanks! You should pin this issue.

only @el1t can do that

Just FIY I would not recommend buying 1Blocker. I paid both for the initial version and the "1Blocker X" one on IOS but I had the constant feeling the filter lists weren't being updated and I wasn't sure of their origin (I'm assuming they use EasyList for the ads, but which one do they use for privacy & annoyances?).

AdGuard for Safari is free, open-source and is compatible with uBlock-style filter lists (it has code that does its best to convert them to Safari content blocking lists). You can choose to use EasyList, EasyPrivacy, Fanboy's lists or any of the regional lists so I would recommend it over 1Blocker.

Adguard for Safari, the most effective, but contains electron (chromium). I'm not entirely sure how it works, but it will cost performance and battery life on your computer so I would avoid it.

  1. Electron is used for the UI part of it only. All other parts are native.
  2. Running the electron part in the background is not necessary. Although, it is recommended so that AG could update filters automatically.
  3. The linked issue was resolved in the latest release

I'm not entirely sure how it works

You can take a look - https://github.com/AdguardTeam/AdGuardForSafari

Adguard for Safari, the most effective, but contains electron (chromium). I'm not entirely sure how it works, but it will cost performance and battery life on your computer so I would avoid it.

1. Electron is used for the UI part of it only. All other parts are native.

2. Running the electron part in the background is not necessary. Although, it is recommended so that AG could update filters automatically.

3. The linked issue was [resolved](https://github.com/AdguardTeam/AdGuardForSafari/issues/210) in the latest release

I'm not entirely sure how it works

You can take a look - https://github.com/AdguardTeam/AdGuardForSafari

Thank you for responding. Ive updated the post and corrected my errors.

Based on point 2, for filters to update, the electron part needs to be running. Does leaving this running for filters to update have any serious power or performance issues?

Just FIY I would not recommend buying 1Blocker. I paid both for the initial version and the "1Blocker X" one on IOS but I had the constant feeling the filter lists weren't being updated and I wasn't sure of their origin (I'm assuming they use EasyList for the ads, but which one do they use for privacy & annoyances?).

AdGuard for Safari is free, open-source and is compatible with uBlock-style filter lists (it has code that does its best to convert them to Safari content blocking lists). You can choose to use EasyList, EasyPrivacy, Fanboy's lists or any of the regional lists so I would recommend it over 1Blocker.

thats odd, when I wrote this post, everything I could find had it as the best or one of the best. This guy tested them quite thoroughly from 2015 to 2018, and found 1Blocker to stand out. Looking at it again now, it seems that 1Blocker requires an app update to update their lists (entirely based on the changelog), which would explain the slow rate of updates. Tommorow I will investigate further and update my list once again.

Based on point 2, for filters to update, the electron part needs to be running. Does leaving this running for filters to update have any serious power or performance issues?

Not really. Here's how it looks on my MBP, and in my case, I am actually actively using it, not just keep it in the background:

There was indeed an issue with the version of Electron we were using previously, but it's now gone.

On the other hand, I share your sentiments about Electron. The UI is generally worse and slower than it could be if we made it native. But it allowed reusing a lot of existing code from the Chrome/FF extensions so here we are.

What about building uBlockOrigin as either a proxy with a root certificate or using applescript and making it a Mac app?

Further options are being discussed in uBlockOrigin/uBlock-issues#145.

@p4t44, you may want to link to the HackerNews discussion of the whys and pros and cons of Apple's change to Safari: https://news.ycombinator.com/item?id=21025252

Based on point 2, for filters to update, the electron part needs to be running. Does leaving this running for filters to update have any serious power or performance issues?

Not really. Here's how it looks on my MBP, and in my case, I am actually actively using it, not just keep it in the background:

There was indeed an issue with the version of Electron we were using previously, but it's now gone.

On the other hand, I share your sentiments about Electron. The UI is generally worse and slower than it could be if we made it native. But it allowed reusing a lot of existing code from the Chrome/FF extensions so here we are.

As AdGuard's performance is far from settled, I've linked here. If it goes fast for you, use it. If it goes slow for you, don't use and delete it.

Just FYI for anyone reading this thread: AdGuard for Mac requires installing a kernel extension which as far as I know none of the other options do. I didn't feel comfortable with that so I went with one of the other options.

I would also suggest Little Snitch or some free equivalent, using block lists. Since it's a firewall, it won't be impacted by any changes in Safari.

I was using a manually installed build of uBlock Origin on Safari, but Safari crashed twice, and uBlock was dissabled.

@p4t44 @freediverx Do you need nifty macos app or just good ad blocker ?
You don't need to run it. Electron app i needed only for rule updates. It can't slow down your safari browser. So i think slowness of this app it's not critical issue. You can run it from time to time just for update rules.

@El-Fitz but functionality of this ad blocker will be limited to blocking hosts when real ad blockers much more powerful and it will diffidently slow down your browser. Better use dnscrypt-proxy with blocklist in this case if you could satisfied by host blockers.

@p4t44

As AdGuard's performance is far from settled, I've linked here. If it goes fast for you, use it. If it goes slow for you, don't use and delete it.

Why? It seems settled that the UI is slow as it's Electron-based, and I don't argue with that. It just has nothing to do with ad blocking performance, and there's no one on this thread complaining about that. Also, "slow" does not mean that it consumes additional energy or whatever. It simply takes more time to render when you decide to use it.

@p4t44

As AdGuard's performance is far from settled, I've linked here. If it goes fast for you, use it. If it goes slow for you, don't use and delete it.

Why? It seems settled that the UI is slow as it's Electron-based, and I don't argue with that. It just has nothing to do with ad blocking performance, and there's no one on this thread complaining about that. Also, "slow" does not mean that it consumes additional energy or whatever. It simply takes more time to render when you decide to use it.

It used to be that it was slower even without the UI open before a recent update. It is also reccomended that you leave the app open constantly for filters to update (which or may not slow it down). I can link you to a dozen reports of AdGuard going slow, so I think it is unreasonable not to mention it in the list.

Slow means that 1) it takes longer to use, 2) uses excessive CPU and memory to make the rest of your computer go slower and 3) use more battery. I'm really not sure wether it is significantly slower then alternatives, and I don't have the time or will to figure it out. I've linked to this thread so anybody unsure can read the comments of the AdGuard developer and decide for himself.

I think that if you are considering AdGuard, download it. Check activity monitor, if it takes up a lot of CPU or battery, uninstall and get something else. If it doesn't, then don't and use it.

I would just like to mention a couple of advantages that Wipr has over Ka-Block:

  • Wipr works with YouTube, while Ka-Block doesn't
  • Wipr is actually made of 3 extensions in order to be able to overcome the 50k rules limitation imposed by Apple, so it can go up to 150k and block more stuff (Ka-Block can fail to block ads on some websites in my experience)
  • I don't know if Ka-Block can do this, but Wipr can automatically update the filter list in background without having the app up and running all the time.

Note that with the new Content Block API you don't need to have a white-list option built into the extension, because you can exclude content blocking on specific websites directly from Safari going to Preferences -> Websites -> Content Blockers

I would just like to mention a couple of advantages that Wipr has over Ka-Block:

* Wipr works with YouTube, while Ka-Block doesn't

* Wipr is actually made of 3 extensions in order to be able to overcome the 50k rules limitation imposed by Apple, so it can go up to 150k and block more stuff (Ka-Block can fail to block ads on some websites in my experience)

* I don't know if Ka-Block can do this, but Wipr can automatically update the filter list in background without having the app up and running all the time.

Note that with the new Content Block API you don't need to have a white-list option built into the extension, because you can exclude content blocking on specific websites directly from Safari going to Preferences -> Websites -> Content Blockers

Updated the post.

If I've known about this, I wouldn't update Safari 😢

@kfur true; it doesn't offer the same level of ad blocking. But how would it slow down the browser? It doesn't run in it, and the requests just fail before even leaving the computer

bois ghostery lite is pretty good

@El-Fitz i think LS was developed not for it. I assume that software like dnscrypt-proxy or system host file will work faster.

FYI, you can install Firefox Focus on iOS and use that as a content blocker in Safari. See https://support.mozilla.org/en-US/kb/focus#w_step-one-allow-safari-to-use-content-blockers-you-only-need-to-do-this-once

I've changed to Firefox now in all my platforms.

And testing the AdGuardHome on a server and then use the DNS filter through Argo tunnel on my Mac for Safari. Seems that this only works as a regular content blocker.

I have downloaded MS Edge Chromium base. UBlock Origin works with it.

Hello :)

@p4t44

Safari content blockers aren't all bad, they are more secure in that they can't possibly collect your browsing history (not that uBO does), but lack the level of customisation and power that a regular blocker like uBO can provide.

Yep. Except for AdGuard Icon and AdGuard Advanced Blocking, all AdGuard extensions don't have access to the page, so they are more secure than uBlock Origin, for example. Then, because they use Safari content blocking API, they can block the elements before they're loaded.


I think AdGuard for Safari is the best option if you like uBlock Origin:

  1. uBlock0 and AdGuard share almost the same filter lists (EasyList, AdGuard Base, EasyPrivacy, Adguard Tracking Protection, etc..), so you have the same - best - ad blocking quality ;)
  2. uBlock0 and AdGuard share almost the same filter syntax, so you can use your user filter list with both of them;
    2.1) AdGuard introduced scriptlets, that are almost compatible with uBlock0 js (see compatibility table here);
    2.2) Compatibility with uBlock0 filters will be improved in the future (see issue here), so you can use uBlock0 filter lists as custom ones.

In addition:

  • with AdGuard for Safari you can inject custom javascripts, for example in order to write a cookie, automatically click an element, etc..
  • you can use uBlock Origin with Firefox and Chrome, basically; on the contrary, you can use AdGuard (so share all you custom rules, filters lists, etc) with all browsers and OS (Windows, macOS, Android, iOS.. ), and this is a great added value :)

PS:
I don't like electron, but as @ameshkov said:

Running the electron part in the background is not necessary

open it - update filters - close it.

PPS:
Thanks @p4t44 for this - explanation of the state of uBlock Origin for Safari - issue ;)

could ub0 be installed as an app, just like iina do with it's safari extension?

could ub0 be installed as an app, just like iina do with it's safari extension?

An app could be made with similar functionality to uBlock Origin, but it wouldn't be uBlock Origin, as it would work completley differently.

commented

Adguard for MacOS has the most complete list and is not restricted to the 50000 rules like the Safari extension. You can even add custom lists from Filterlist for a more fine tuned list like Facebook ads or Youtube comments and so on. The price of the app is not cheap but it works system wide and as so on all browsers installed.

@stephanepiriou

Adguard for MacOS has the most complete list and is not restricted to the 50000 rules like the Safari extension.

Just to clarify: with AdGuard for Safari the total number of rules that can be used simultaneously is 300.000 (50.000 per group) :)

Btw, as you said, AdGuard for Mac can

  • filter your traffic in all browsers and apps on your Mac
  • have an unlimited number of filter rules
  • provide a better filtering quality (due to the lack of browser API restrictions)

(see details here and here)

commented

FYI, Adguard for Mac, as a system-wide app, installs its own root SSL certificate to the system and does MitM. And it is not open source.

best option for Safari users? to stay on Safari 12.1.2 😬

best option for Safari users? to stay on Safari 12.1.2 😬

Safari 13 will come with macOS Catalina later this year, so may not be a good permanent solution for most people.

commented

Which one from the App Store is the most efficient in terms of CPU/memory/energy?

commented

I'm curious what the differences between Safari and Firefox Beta/Developer/Nightly are in terms of CPU load and battery consumption. Does anyone have a benchmark on that?

Which one from the App Store is the most efficient in terms of CPU/memory/energy?

Do you need whitelisting or constant filter updating? If not, I think they all should be the same.

I'm curious what the differences between Safari and Firefox Beta/Developer/Nightly are in terms of CPU load and battery consumption. Does anyone have a benchmark on that?

Haven't seen anything comparing to Safari, but here it is comapred to Chrome.

https://bugzilla.mozilla.org/show_bug.cgi?id=1429522#c45

commented

Do you need whitelisting or constant filter updating? If not, I think they all should be the same.

I don't mind. If they theoretically perform the same and does its job then fair enough.
But still, a comparison of all the apps would be nice to see.

Well my two cents: Adguard is working well for me combined with the built in Safari content blocker. I'd been using Unicorn Blocker but something changed with Safari recently and I couldn't fine tune the rules to block things without breaking other things. Not noticing any added overhead on my 2013 MacBook Pro 13". The only thing I'll say is that when you add a custom filter in Adguard, it does take 2-3 seconds for it to process before letting you add another. So if they could improve that performance, that would be great.

@autigers1970 we definitely will improve the overall UI performance in the next update (v1.6). It's just we were more focused on the adblocking quality, but it seems it's time to focus on other things for some time.

best option for Safari users? to stay on Safari 12.1.2 😬

Safari 13 will come with macOS Catalina later this year, so may not be a good permanent solution for most people.

this is in anyway not a recommendable solution, since there may be severe bugfixes in future releases... was more of a joke...

Safari is dead. I have to accept it.

commented

Sadly after researching these recommendations, they all feel like consolation prizes compared to uBlock_0. I really hope someone with the same comprehension and standards recreates the project as a compliant(?) Safari extension even with reduced features due to new limitations.

Sadly after researching these recommendations, they all feel like consolation prizes compared to uBlock_0. I really hope someone with the same comprehension and standards recreates the project as a compliant(?) Safari extension even with reduced features due to new limitations.

I think that AdGuard for Safari does everything that uBO does that can be possibly implemented into Safari.

Using Firefox when this scrolling issue is still around? Ick... Really going to miss uBO-Safari. 😢

It will not possible for uBlock Origin to work with the upcoming Safari 13 / macOS Catalina release

@p4t44 Have you looked at the possibility of creating a Safari App Extension (which is not the same as a content-blocker extension)? You can inject JavaScript into any page, listen to beforeload and block those events if required. I've tried these in macOS Catalina and all of this works.

The downside is that there's no "global" area for scripts or resources -- that is now the Swift code, and there's no way to call Swift code and get back an answer synchronously (i.e. no canLoad equivalent exists). This implies that all JavaScript needs to get injected into every page and on every reload, which might affect performance and/or memory footprint.

It will not possible for uBlock Origin to work with the upcoming Safari 13 / macOS Catalina release

@p4t44 Have you looked at the possibility of creating a Safari App Extension (which is not the same as a content-blocker extension)? You can inject JavaScript into any page, listen to beforeload and block those events if required. I've tried these in macOS Catalina and all of this works.

The downside is that there's no "global" area for scripts or resources -- that is now the Swift code, and there's no way to call Swift code and get back an answer synchronously (i.e. no canLoad equivalent exists). This implies that all JavaScript needs to get injected into every page and on every reload, which might affect performance and/or memory footprint.

I'm not the develoeper and don't really understand how any of it works. I just spent far to long scraping together why uBO stopped working in Safari when I upgraded to the Catalina beta, and thought I would try to explain after a lot of posts on /r/ublockorigin had the same issue as me. The developer who made ublock-safari also hasnt updated it for over a year even before Safari 13. But if you or anyone else thinks they can make it work, please do.

@p4t44 I understand your position now. Sorry, I'm afraid I don't think I can work on this as of now. I'd be happy to help anyone else who wants to take it up, though.

... Though it is still curently possible to install uBlock Origin by downloading the extension from Github (edit: must follow these instructions, it will not be starting from Safari 13 / macOS Catalina, when the legacy entension API will be fully deprecated.

This doesn't work anymore as the “Show Extension Builder” command in the “Develop” menu no longer exists (Safari 13 on macOS 10.14.6).

... Though it is still curently possible to install uBlock Origin by downloading the extension from Github (edit: must follow these instructions, it will not be starting from Safari 13 / macOS Catalina, when the legacy entension API will be fully deprecated.

This doesn't work anymore as the “Show Extension Builder” command in the “Develop” menu no longer exists (Safari 13 on macOS 10.14.6).

That was written before Safari 13 was released, fixed now.

FWIW, if you still haven't updated to Safari 13, you can run:

softwareupdate --ignore Safari13.0.1MojaveAuto

to hide the Safari 13 update...

Thank you! I’d like to see https://better.fyi added to the list. Costs 2,99 and is open source.

Thank you! I’d like to see https://better.fyi added to the list. Costs 2,99 and is open source.

I disagree that better is a good choice in comparison to the other options. Though I have not personally tested it, it only seems to have one content blocker so its blocking power will be less than alternatives such as AdGuard (free) or Wipr (also $1.99). It seems like an unexceptional paid content blocker from what I have seen about it.

@p4t44 thank you very much for the advice!!! 1Blocker the best.

I think the current developer and those who had hoped to carry on have made it clear that this isn’t a matter of money. Current Apple rules won’t allow anything like uBlock to perform as it used to.

@alvarnell yeah I deleted the post since I wanted to look into it more. I found https://github.com/dgraham/Ka-Block which is a good prototype of ideas but am trying to understand more so how ublock works so i can understand if there is a similar approach.
Im all ears for what apple rules make this not feasible compared to ublock origin (like specific workflows or functions that handle stuff I could see in ublock or where a feature like NSExtensionRequestHandling fails).

If theres somewhere its spelled out by an actual dev that would be helpful. From my completely uninformed view it seems like the issue is that all the handling done in js would be done in swift, what parts of the old code can even be reused? I have no idea

@alvarnell yeah I deleted the post since I wanted to look into it more. I found https://github.com/dgraham/Ka-Block which is a good prototype of ideas but am trying to understand more so how ublock works so i can understand if there is a similar approach.
Im all ears for what apple rules make this not feasible compared to ublock origin (like specific workflows or functions that handle stuff I could see in ublock or where a feature like NSExtensionRequestHandling fails).

If theres somewhere its spelled out by an actual dev that would be helpful. From my completely uninformed view it seems like the issue is that all the handling done in js would be done in swift, what parts of the old code can even be reused? I have no idea

Take a look at AdGuard for Safari, https://github.com/AdguardTeam/AdGuardForSafari. It is open source and supports as much of the functionality of uBlock Origin as is reasonably feasible in Safari.

As I understand currently an app / extension can send Safari content blocking rules which Safari enforces. This is contary to how uBlock Origin works, where you give the rules to uBO and it enforces them. If you want to create a Safari app / extension which replicated the functionality of uBO in Safari as much as possible that would be great but I'd recommend not using the uBO name / "brand" for the project (as it would not share any of the code or inner workings with uBO, it should go by a different name to avoid confusion. uSafari?). You might also like to use AdGuard as a base.

@grahamannett I don't mean to be mean, but as a New Yorker I can't help but be direct. It seems like you didn't give much weight to all of the effort that went into the explanation at the top of this issue, effort by @p4t44 and people who contributed edits to that explanation via comments.

If you want confirmation from @el1t himself, then take a look at which issue he pinned to the top of the issues list. This pin, as far as I know, is his latest and final comment on uBlock for Safari. In addition, the explanation above contains a link to a statement by @gorhill himself.

If you want more technical details, follow the links, e.g. the Hacker News discussion.

commented

Hey guys, did you check out the new macOS update? could it help us somehow?

Screen Shot 2020-03-26 at 12 59 25 PM

URL: https://developer.apple.com/documentation/macos_release_notes/macos_catalina_10_15_4_release_notes

@alfonmga All Catalyst does is allow UIKit apps (those built for iOS) to be easily ported to run on MacOS. This does not in any way loosen restrictions on Safari plugins/extensions.

Apple has promised its users to build an impenetrable wall around user's privacy. There simply is not a way to allow third party code to do content-filtering without giving that code access to a user's entire browsing history. We can't have our cake and eat it too.

Content Blocker is Apple's solution to this problem: Third parties supply Safari with filtering rules, not code. Unless uBlock Origin adopts that (it won't), uBlock Origin will never work in Safari.

@vassudanagunta

Apple has promised its users to build an impenetrable wall around user's privacy. There simply is not a way to allow third party code to do content-filtering without giving that code access to a user's entire browsing history. We can't have our cake and eat it too.

Except that just about every content blocker has another extension included which can see your entire browsing history for whitelisiting. They haven't built an impenetrable wall around users privacy, they have built an impenetrable wall around user customisation and choice.

Also you can have your cake and eat it too in any other browser by being careful and not installing malicious extensions.

@p4t44 I think your take is an oversimplification. The beauty of it is they don't have a monopoly; the people who prefer the kind of user customization you want can have it: Firefox. Or Linux.

But for people who don't want it at the expense of security, even super technical people like me, and people who like me have spent countless hours digging non-technical people out of malware holes, or get pissed off at all the con-artists taking advantage of people confused by complexity (most people, including us technical people), we are glad that we have the choice to choose a more locked down platform.

Just as you said, it's all about choice and Apple is the only vendor in this space offering that choice.

Another point regarding 1Blocker, it now requires 10.15 Catalina.

Thankfully I'm still using an old version that works on 10.14 Mojave.

Ad-Guard works well on macOS 10.15, it’s open source and you can disable 2 out of its 8 Safari extensions to prevent it from having any access to your website data, it also allows custom filters.
App Store version: https://apps.apple.com/us/app/adguard-for-safari/id1440147259?mt=12

GitHub source code: https://github.com/adguardteam/adguardforsafari#

@Baccount
I agree, and AdGuard for Safari supports most of uBlock0 syntax (e.g. scriptlets) :)

Seems like they announced web extensions on the WWDC, could this eventually mean that add-ons like uBlock might be possible again with the next OS version?

They do say New support for the WebExtensions API so I'm hopeful that they actually support the whole range of it, with the restriction of the user having to enable the add-on explicitly

More info here:
https://developer.apple.com/documentation/safariservices/safari_web_extensions

Compatibility and limitations:
https://developer.apple.com/documentation/safariservices/safari_web_extensions/assessing_your_safari_web_extension_s_browser_compatibility

The most important limitation for blockers is this part:

  • webRequest
    • BlockingResponse not supported.
    • Blocking requests not supported.

It basically means that we have to continue using their Safari Content Blocking API.

Ugh, their Safari Content Blocking API is worthless, at least based on every content blocker I’ve tested. So much for that idea. Damnit, Apple.

Send feedback to Apple via the Feedback app once you’re able to run a beta! 🙂

I could be wrong, but those docs look the same as the ones before today. Meaning I'm not so sure they've updated their documentation site with the new APIs

https://www.reddit.com/r/uBlockOrigin/comments/hdz0bo/will_ublock_origin_back_to_macos_big_sur/fvoc7wk/

Apparently not, this is what it says for the webRequest API:

BlockingResponse not supported.

Blocking requests not supported.

Edit: There are other unsupported API methods:

  • onCreatedNavigationTarget (to deal with unwanted popups);
  • minimal support for insertCSS: no user styles, can't inject on a per-frame basis;
  • No privacy API;

Send feedback to Apple via the Feedback app once you’re able to run a beta! 🙂

Apple doesn't make what users want, Apple makes what they want users to want. Besides the overwhelming majority of Apple user/fan base is always happy with what Apple makes or tries/claims to make.

Here's a fine option if you're comfortable with blocking via /etc/hosts: https://github.com/StevenBlack/hosts.git -- as a bonus, it can optionally block fakenews, porn and other such junk.

@ameshkov Please correct the disinformation in this picture which purports to compare AdGuard for Safari to other blockers on Safari: https://cdn.adguard.com/public/Adguard/Blog/safari-compare.jpg I have no doubt you are well aware that "UBlock" on Safari is not uBO.

@gorhill uh, wrong logo? sorry for that, we'll fix it. May I ask where you found that picture?

https://adguard.com/en/adguard-safari/overview.html, "What's the difference between AdGuard for Safari and other ad blockers? ".

So.. is ubo coming to new safari and big sur? I dont really understand all this technical speak

So.. is ubo coming to new safari and big sur? I dont really understand all this technical speak

No. https://www.reddit.com/r/uBlockOrigin/comments/hdz0bo/will_ublock_origin_back_to_macos_big_sur/fvoc7wk/

Use uBo in firefox or chrome, or use adguard in safari.

FYI, it seems that Wipr no longer supports blocking YouTube ads: https://www.reddit.com/r/MacOS/comments/hs16jl/what_is_going_on_with_wipr/

Just FIY I would not recommend buying 1Blocker. I paid both for the initial version and the "1Blocker X" one on IOS but I had the constant feeling the filter lists weren't being updated and I wasn't sure of their origin (I'm assuming they use EasyList for the ads, but which one do they use for privacy & annoyances?).

AdGuard for Safari is free, open-source and is compatible with uBlock-style filter lists (it has code that does its best to convert them to Safari content blocking lists). You can choose to use EasyList, EasyPrivacy, Fanboy's lists or any of the regional lists so I would recommend it over 1Blocker.

Mac preferences> safari extensions - says permission to read sensitive data including passwords and logins! is that ok?

So.. is ubo coming to new safari and big sur? I dont really understand all this technical speak

No. https://www.reddit.com/r/uBlockOrigin/comments/hdz0bo/will_ublock_origin_back_to_macos_big_sur/fvoc7wk/

Use uBo in firefox or chrome, or use adguard in safari.

safari extension preferences say - permission to read sensitive information including passwords and logins. Do they store these information?

Mac preferences> safari extensions - says permission to read sensitive data including passwords and logins! is that ok?

Only if you want it to work, otherwise it won't.

permission to read sensitive information including passwords and logins. Do they store these information?

Only locally and only what is necessary for its use.

Hi,
I decided to switch back to Safari as my main browser for battery reason and discovered that uBlock Origin is not compatible anymore. After reading most of the possible solutions I think I came up with a pretty acceptable outcome: using NextDNS.

Nextdns is a (free for basic usage) DNS resolver, when you create an account you can select blocklists, which does include for example Easylist:
Screenshot 2020-09-01 at 14 21 09

The only downside is that there is no menu action on webpage to say "whitelist this website", it has to be done on the configuration page of nextdns.

Cheers,

ps: I'm not affiliated with NextDNS in anyway, just a happy user

Also should be mentioned that with services like NextDNS you basically reroute all of your net activity through their service which is... let's say not ideal in a privacy kind of sense. (Even if they claim to do nothing with that data)