Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Safari Version #1596

Closed
philipamour opened this issue Apr 27, 2016 · 59 comments
Closed

Safari Version #1596

philipamour opened this issue Apr 27, 2016 · 59 comments

Comments

@philipamour
Copy link

There doesn't seem to be a Safari version of uBlock Origin, therefore I would like to request it.

@lewisje
Copy link

lewisje commented Apr 27, 2016

Who wants to maintain the platform-specific bits and pay for the external server (because Apple doesn't host Safari extensions on its own servers the way all other browser extension platforms do)? (NOTE: I failed to realize that even as of the time I made this comment, Apple had moved to hosting all extensions in the Gallery, so that barrier is gone.)

I remember when @chrisaljoudi tried that out and it quickly overwhelmed him; I actually bought a used Mac (but one that could still run El Capitan) with part of my Christmas bonus with the intention to port uBO to Safari, and I just haven't been arsed to get down to work on it, and even then, I'd be looking for someone else to take over that port and set up proper servers, because right about now I don't feel like paying the $99 per year for the privilege of building signed Safari extensions.

@philipamour
Copy link
Author

@lewisje Thanks! Hope you like your Mac! $99/year for being able to publish apps to the macOS, tvOS & iOS App Store is a steal. I used to pay $200 to have both macOS and iOS dev membership.

@5t3f4n
Copy link

5t3f4n commented Apr 28, 2016

@lewisje if the $99 is the only thing standing in your way, I'd be happy to pay it for you. But since it's an annual fee, maybe we could hold off on doing that until you've reach at least "public beta tier" stability so that already paid for months don't go unused.

I believe I tried to pursueade @gorhill into installing OS X in a VM once but I guess he simply doesn't have the time and/or interest. I'd even offer remote access to an actual Mac if necessary.

By the way, would the Safari fork utilize the new content blocking API in any way or would that mean most of uBlock Origin's codebase would be unusable?

@lewisje
Copy link

lewisje commented Apr 28, 2016

I honestly haven't looked into the new API enough to answer your question intelligibly.

@gorhill
Copy link
Owner

gorhill commented Apr 28, 2016

doesn't have the time

This is it. Even if I was going into a coding marathon to make a workable version, I would have to maintain and address specific issues. I just do not have the time for this.

@Hrxn
Copy link

Hrxn commented Apr 29, 2016

I think I have posted this link on another issue thread before, but I guess it's still relevant:

GH:
https://github.com/infernoboy/JavaScript-Blocker-5
HP:
http://jsblocker.toggleable.com/

Features

  • Quickly and easily block advertisers, tracking agencies, and social media networks from monitoring your online activity.
  • Prevent all scripts on the webpage from being allowed to run.
  • Prevent links from sending referrer information.
  • Block frames, XHRs, embeds, objects, videos, and hide images.
  • Block many annoyances such as alert dialogs popping up, forms not autocompleting, windows being resized, and more.
  • Full support for Greasemonkey-style user scripts so you can make webpages work exactly how you want them to.
  • Canvas fingerprinting protection.

It doesn't use the new Safari Blocking API, apparently, because of some strange limitation. (Note: This might be outdated, I have no idea if it still applies)

About Safari's New Content Blocker API
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.

@lewisje
Copy link

lewisje commented Apr 29, 2016

Oh yeah, so it's the same API used in iOS, and that means a whole new extension would need to be created if that API were relied on.

@AndyWendt
Copy link

AndyWendt commented May 8, 2016

Maintaining a proprietary Safari version would be quite time consuming. Sounds like a good case for a fork (changed from incorrect PR) from somebody who uses Safari/Mac (Used to but I don't now that I found the land of milk and honey which is linux).

@gorhill
Copy link
Owner

gorhill commented May 8, 2016

The solution to time-consumption is not to shift the time-consumption issue onto someone else.

@lewisje
Copy link

lewisje commented May 8, 2016

^^I think you meant "fork" rather than PR.

@Hrxn
Copy link

Hrxn commented May 9, 2016

The solution to time-consumption is not to shift the time-consumption issue onto someone else.

Coming soon to a http://www.brainyquote.com/ near you.. ;-)

[..] now that I found the land of milk and honey which is linux.

If I only had known! Don't get me wrong, I like Linux too, but it comes with its own set of disadvantages and problems. The culprit is usually not the Linux kernel itself, ironically..

@tiberian83
Copy link

A Safari version would be highly appreciated. I hope @gorhill will change his opinion about it.

@jellyfishcoder
Copy link

jellyfishcoder commented Jun 14, 2016

Safari 10 has a new API that is much better than the old one, it is now distributed via the Mac app store, but the safari 10 is only is macOS Sierra, which is in beta. It allows for more access than the old content blocker API

@kenips
Copy link

kenips commented Jul 3, 2016

Actually Safari 10 will be available for 10.10+. Only Apply Pay on the Web, multiple results suggestion, and Picture in Picture are exclusive to 10.12. So any effort into making a Safari 10 Extension will benefit most Safari users once Safari 10 is released.

@freediverx
Copy link

freediverx commented Jul 10, 2016

I realize Apple has created their own framework for Safari extensions. But it's been a year and I have yet to see any Safari ad blockers that come close to the effectiveness and functionality of uBlock. I am still using the original, no longer supported version of uBlock for Safari and it works better than any of the newer ones offered via Apple's App Store.

Bear in mind that Apple has not blocked the installation of Safari extensions outside of their store, even in the current beta of macOS Sierra, due to be released this fall.

For anyone who uses a Mac, Safari is arguably the best available web browser by far. It is the most secure, most stable, and the one that uses the least resources and battery power - not to mention support for numerous native Apple features such as Reader mode and tab/favorites/password syncing.

What would it take to persuade the devs to create a version for Safari? I would happily pay a premium for it, and I'm certain there are many others who would as well. Also note that Apple users are not as stingy as those on other platforms (ducks!) so it's likely you would find a very receptive audience to a paid version of the extension.

@ELLIOTTCABLE
Copy link

What @freediverx, @philipamour, and @5t3f4n said: those of us using OS X, Mac laptops, and software written for OS X, are generally willing to pay money (which is a pretty foreign concept to a lot of the privileged fedora-wearing circles) for software.

I don't even remotely have the time to assault a port, even though it honestly sounds like a lot of fun to me; but I am definitely willing to pay monthly for a port.

Given that a Safari version is, 1. a substantial diversion from the existing codebase (both to be developed, and subsequently maintained), due to Safari's unique Content Blockers APIs; and 2. a platform that the developers of uBlock neither use, nor personally care about … I think it's totally reasonable for the Safari version to be separate, and pay-only. Even if that, specifically, isn't something that you, the developers, wish to pursue, I'd like to posit that even given a slightly lukewarm response from one of you … those of us interested would be happy to pledge to a Gratipay-née-Gittip, or Patreon, or similar, to fund the time-investment in learning and working on a new platform.

@zorrobyte
Copy link

I'd host a download server for a Safari version of Adblock.

@lewisje
Copy link

lewisje commented Aug 22, 2016

I think you mean uBlock Origin: Both ABP and AdBlock have Safari versions, with their own dedicated download servers.

@tangestani
Copy link

@lewisje An easy solution would be to just host it from the GitHub repo.

@lewisje
Copy link

lewisje commented Aug 24, 2016

That's an abuse of GitHub's resources.

@tangestani
Copy link

@lewisje Calling it an abuse of resources is a bit of a stretch. Many projects are downloaded and installed directly from GitHub. And I'm pretty sure most of them are much larger than 4MB.

@lewisje
Copy link

lewisje commented Aug 25, 2016

It's not a stretch, it's precisely why @gorhill didn't have the Firefox builds just auto-update from GitHub (AMO does provide free hosting, but the approval process takes a long time per revision): uBlock-LLC/uBlock#925 (comment)

Also, if by "many projects" you mean Node stuff, most of them are installed from NPM, which uses a CDN (that is not GitHub) to host copies of the relevant files.

@zorrobyte
Copy link

How much bandwidth are we talking? Would 1-2 TB a month on a gigabit line do it or would it be much more?

@lewisje
Copy link

lewisje commented Aug 25, 2016

I really haven't been following the Apple news well; it turns out that for more than a year, it has been possible to directly host extensions on the Safari Extension Gallery, as long as you have an active Apple Developer Account ($99/year): https://macmule.com/2015/11/18/deploy-updating-safari-extensions-on-safari-9/

In Safari 9+, the Gallery is the only means for auto-updating extensions.

@freediverx
Copy link

And if for some reason this presents a big hurdle to the devs, many of us would be happy to manually update if it were distributed elsewhere.

On Aug 25, 2016, at 8:49 AM, James Edward Lewis II notifications@github.com wrote:

I really haven't been following the Apple news well; it turns out that for more than a year, it has been possible to directly host extensions on the Safari Extension Gallery, as long as you have an active Apple Developer Account ($99/year): https://macmule.com/2015/11/18/deploy-updating-safari-extensions-on-safari-9/ https://macmule.com/2015/11/18/deploy-updating-safari-extensions-on-safari-9/
In Safari 9+, the Gallery is the only means for auto-updating extensions.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub #1596 (comment), or mute the thread https://github.com/notifications/unsubscribe-auth/AE2rq9mjDGvMadtdSYgXnyAtX-eO5qLfks5qjY9ogaJpZM4IQ8fF.

@lewisje
Copy link

lewisje commented Aug 25, 2016

Honestly, for an extension as popular as this, it's probably more cost-effective to use the Gallery than to host on an external server.

@isadon
Copy link

isadon commented Aug 25, 2016

@lewisje Definitely, $99/yr is definitely way better cost and time wise than having to deal with the maintenance of a shared hosting/vps/dedicated server. I am an iOS/backend developer with an Apple dev account and I wanted to take a crack at looking into what it would take to make uBlock Origin work on Safari but HTML/CSS/JS (webkit) Safari Plugin development is not my forte, the idea does excite me though. However I personally think this is something mac users would definitely pay for. I wouldn't pay monthly for it, but a small one time fixed fee of $5, $10? Mac users would pay. In addition to that If a fixed one time fee doesn't cover it donations on the main site can be used in addition to the fixed fee to maintain active development. I think the key takeaway here is the demand is definitely there.

@ghost
Copy link

ghost commented Aug 25, 2016

If we're talking about Safari, then why not go all out and do complete content blocker versions of uBlock instead of a simple extension? This way it can be used in both iOS and macOS and you could make it like $1 to cover some of the costs? I believe the content blocker API is far more advanced than just doing an extension.

@lewisje
Copy link

lewisje commented Aug 25, 2016

The content-blocker API is much more limited than ABP-style filter-lists; ABP itself, in its experimental content-blocking support for Safari, internally translates a subset of EasyList to the content-blocker format, because that's all the API can handle.

It's a much better idea to port the current uBlock Origin for Chrome codebase to work in Safari, and then maybe code a whole new app for iOS; BTW, a content-blocker variant for newer versions of Safari on macOS would still be an "extension" rather than some sort of standalone app.

@freediverx
Copy link

Totally agree. I have no interest in a content-blocker as limited as those available on iOS. The whole point of this is to get the full functionality of uBlock in an updated Safari extension, and that includes filter lists as well as the ability to manually select and block page elements.

On Aug 25, 2016, at 3:13 PM, Todd notifications@github.com wrote:

If we're talking about Safari, then why not go all out and do complete content blocker versions of uBlock instead of a simple extension? This way it can be used in both iOS and macOS and you could make it like $1 to cover some of the costs? I believe the content blocker API is far more advanced than just doing an extension.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

@gemnioo
Copy link

gemnioo commented Sep 13, 2016

Since Adblock Plus now sells ads. Pls develop Safari version

@niemyjski
Copy link

+1

@DavidSchechter
Copy link

+1 for Safari version

@joelruns
Copy link

+1 though I understand the pain of the devs here :(

@LRFLEW
Copy link

LRFLEW commented Sep 14, 2016

I'd be interested in a Safari version, and would even be willing to try to help. (I don't have a lot of experience with extension creation, but I do know javascript and mac development). Though, I do have a question: can this be built as a Tampermonkey script? I already have Tampermonkey installed as an extension in Safari for another plugin, and would be willing to add this. I realize it's not a complete replacement for being its own extension, but it could be something to make testing and development on the browser easier.

@lewisje
Copy link

lewisje commented Sep 15, 2016

uBlock Origin requires capabilities specific to browser extensions, which TamperMonkey scripts cannot use.

@ludalex
Copy link

ludalex commented Sep 16, 2016

👍

@mustii82
Copy link

Im Ready to upload the signed Extension via my Developer Account. So you mustn't pay 99$/Year

@stonevil
Copy link

Me too. I'm ready to sign and upload safari extension with my premium developer account. Less to worry.

@yacut
Copy link

yacut commented Sep 23, 2016

@lewisje, I'm ready help you with port or testing.

@christopherredden
Copy link

You can currently clone the repo, build the Safari version and manually install it with the extension builder. Is there anything missing besides uploading a signed extension?

@brianmbutler
Copy link

@topherredden

Nope, I've done it on my machine locally. Without the signature you can't put it in the gallery or app store if Apple puts extensions there in the future. Did you try to test it on Tech preview 14?

@lewisje
Copy link

lewisje commented Oct 5, 2016

^^I've been so lazy about it that I didn't even consider doing that; I thought there was a bunch of Safari-specific stuff that needed to be updated.

@Masterj2700
Copy link

I would love to use ublock origin for safari. Are there any current plans to allow this. @topherredden how do I build and import a clone? @lewisje

@Coriou
Copy link

Coriou commented Oct 13, 2016

As mentioned before by others, I'd also be happy to help (dev, test, sign, ...) because I really like Safari 10 (finally) and I really would like Ublock Origin to be available to everyone using Safari, instead of AdBlock Plus.

@mustii82
Copy link

Lets Build!

@gorhill
Copy link
Owner

gorhill commented Oct 13, 2016

Closing/locking issue due to nothing more than noise being added to it, which contributes nothing. This issue can be resolved in only one way: somebody do the actual work rather than just talk about it -- just as was done for Firefox, Android, Edge, etc. Best if done as a separate project like the Edge port.

@gorhill gorhill closed this as completed Oct 13, 2016
Repository owner locked and limited conversation to collaborators Oct 13, 2016
Repository owner unlocked this conversation Dec 4, 2016
@el1t
Copy link

el1t commented Dec 4, 2016

Hey all, I have a (mostly) working Safari port, with a signed test release if you wish to try it! I've only been able to test it on Safari 10, but it should work on earlier versions. There's more bugs to work out, but the main functionality is there. PRs are welcome! (At the moment, this is more or less an update of the safari extension, not a content blocker app extension)

@euf
Copy link
Contributor

euf commented Dec 5, 2016

@el1t Thanks for your build! I am using it several hours and it seems to work great.

@gorhill Maybe you can add a link to this project to the Readme.md?

@freediverx
Copy link

freediverx commented Dec 5, 2016 via email

@LRFLEW
Copy link

LRFLEW commented Dec 5, 2016

I am running the Safari port now. I ran into a serious issue when updating the filters, having the entire browser crash when I tried to update multiple times. It appeared to update some of them each time I hit update (despite the crash), and now I have all of them saying that they're up-to-date (except EasyList, which keeps saying out-of-date even without the update causing crashes anymore). Otherwise, it seems to be working fine for me. 👍

@el1t
Copy link

el1t commented Dec 5, 2016

@LRFLEW That's definitely a problem! We should move bug reports/discussion here to avoid cluttering this thread, though 😄 I'll need some details to help (Safari version, MacOS version, other installed extensions, etc.).

@mustii82
Copy link

mustii82 commented Dec 5, 2016

I have Filter update problems too :/

@jrozelle
Copy link

jrozelle commented Dec 6, 2016

Same here. But still installed :-)

@lewisje
Copy link

lewisje commented Dec 6, 2016

This Issue needs to be locked again, so that further comments will go to the fork.

@gorhill
Copy link
Owner

gorhill commented Dec 6, 2016

Yes, I unlocked it just so that @el1t could announce the Safari port to all those who have been waiting.

Repository owner locked and limited conversation to collaborators Dec 6, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests