14 ms·
UBlock Origin 1.17.4 released
- vtesucks 8y agoAre there benchmarks where the wasm engine of a browser beats the Js engine of the same browser in compute heavy code?
- adonese 8y agothey attached a benchmark, https://raw.githack.com/gorhill/uBlock/master/docs/tests/hnset-benchmark.html https://raw.githack.com/gorhill/uBlock/master/docs/tests/hns...
- hornetblack 8y agoResults on mine: Benchmarking, the higher ops/sec the better. Firefox 63.0 on Windows 10 64-bit. Test 100 needles against 16 dictionaries of hostnames - Set-based x 1,443 ops/sec ±3.46% (54 runs sampled) - Regex-based x 4,093 ops/sec ±1.18% (25 runs sampled) - Trie-based (1st-gen) x 8,993 ops/sec ±1.92% (59 runs sampled) - Trie-based JS (2nd-gen) x 7,923 ops/sec ±2.81% (44 runs sampled) - Trie-based WASM (2nd-gen) x 10,100 ops/sec ±1.75% (54 runs sampled) Done.
- pietroglyph 8y agoInterestingly, my numbers are completely different relative to each other when compared with yours... I wonder how the number of runs is determined and if this affects the results. Benchmarking, the higher ops/sec the better. Firefox 63.0 on Fedora 64-bit. Test 100 needles against 16 dictionaries of hostnames - Set-based x 1,707 ops/sec ±1.93% (60 runs sampled) - Regex-based x 4,078 ops/sec ±0.88% (25 runs sampled) - Trie-based (1st-gen) x 10,038 ops/sec ±1.41% (64 runs sampled) - Trie-based JS (2nd-gen) x 7,258 ops/sec ±1.03% (40 runs sampled) - Trie-based WASM (2nd-gen) x 8,033 ops/sec ±1.08% (44 runs sampled) Done.
- DiabloD3 8y agoBenchmarking, the higher ops/sec the better. Firefox 65.0 on Windows 10 64-bit. Test 100 needles against 16 dictionaries of hostnames - Set-based x 1,647 ops/sec ±2.23% (13 runs sampled) - Regex-based x 1,178 ops/sec ±4.95% (48 runs sampled) - Set-based x 1,854 ops/sec ±1.94% (59 runs sampled) - Trie-based (1st-gen) x 275 ops/sec ±4.61% (56 runs sampled) - Regex-based x 2,947 ops/sec ±2.32% (61 runs sampled) - Trie-based (2nd-gen) x 671 ops/sec ±2.60% (47 runs sampled) Done. - Trie-based (1st-gen) x 9,311 ops/sec ±1.61% (51 runs sampled) - Trie-based JS (2nd-gen) x 7,121 ops/sec ±1.28% (40 runs sampled) - Trie-based WASM (2nd-gen) x 7,983 ops/sec ±2.44% (63 runs sampled) Done. And mine seems to look different than yours, but similarly lopsided.
- Nullabillity 8y agoThat's what I got too: Benchmarking, the higher ops/sec the better. Firefox 63.0 on Linux 64-bit. Test 100 needles against 16 dictionaries of hostnames - Set-based x 1,992 ops/sec ±0.71% (15 runs sampled) - Regex-based x 5,148 ops/sec ±0.18% (30 runs sampled) - Trie-based (1st-gen) x 11,797 ops/sec ±0.49% (63 runs sampled) - Trie-based JS (2nd-gen) x 8,471 ops/sec ±0.50% (47 runs sampled) - Trie-based WASM (2nd-gen) x 9,543 ops/sec ±0.48% (52 runs sampled) Done. I don't see why trie matching performance would depend on the host OS... Unless WASM runs out of process and requires some form of IPC, I guess?
- wcdolphin 8y agoInteresting that an iPhone XS is the fastest of all the benchmarks above. Benchmarking, the higher ops/sec the better. Safari 12.0 on Apple iPhone (iOS 12.1). Test 100 needles against 16 dictionaries of hostnames - Set-based x 3,763 ops/sec ±0.19% (68 runs sampled) - Regex-based x 392 ops/sec ±0.16% (66 runs sampled) - Trie-based (1st-gen) x 20,669 ops/sec ±0.15% (69 runs sampled) - Trie-based JS (2nd-gen) x 16,926 ops/sec ±0.71% (69 runs sampled) Done.
- X-Istence 8y ago
- X-Istence 8y agoBenchmarking, the higher ops/sec the better. Safari 12.0.1 on OS X 10.14.1. Test 100 needles against 16 dictionaries of hostnames - Set-based x 3,801 ops/sec ±1.01% (62 runs sampled) - Regex-based x 370 ops/sec ±0.68% (60 runs sampled) - Trie-based (1st-gen) x 15,679 ops/sec ±0.73% (63 runs sampled) - Trie-based JS (2nd-gen) x 16,408 ops/sec ±2.50% (62 runs sampled) Benchmarking, the higher ops/sec the better. Firefox 63.0 on OS X 10.14. Test 100 needles against 16 dictionaries of hostnames - Set-based x 1,703 ops/sec ±3.46% (57 runs sampled) - Regex-based x 4,210 ops/sec ±1.95% (26 runs sampled) - Trie-based (1st-gen) x 9,961 ops/sec ±0.74% (65 runs sampled) - Trie-based JS (2nd-gen) x 7,120 ops/sec ±0.61% (40 runs sampled) - Trie-based WASM (2nd-gen) x 7,993 ops/sec ±0.81% (44 runs sampled) Benchmarking, the higher ops/sec the better. Chrome 70.0.3538.110 on OS X 10.14.1 64-bit. Test 100 needles against 16 dictionaries of hostnames - Set-based x 3,414 ops/sec ±5.66% (53 runs sampled) - Regex-based x 4,667 ops/sec ±2.50% (28 runs sampled) - Trie-based (1st-gen) x 10,665 ops/sec ±1.31% (56 runs sampled) - Trie-based JS (2nd-gen) x 7,852 ops/sec ±1.66% (43 runs sampled) - Trie-based WASM (2nd-gen) x 11,930 ops/sec ±2.49% (58 runs sampled) MacOS 10.14.1 Hardware: MacBook Pro (15-inch, 2017) Processor: 2.9 GHz Intel Core i7 Memory: 16 GB 2133 MHz LPDDR3 Graphics: Radeon Pro 560 4096 MB Intel HD Graphics 630 1536 MB
- xhruso00 8y agoBenchmarking, the higher ops/sec the better. Safari 11.1.2 on OS X 10.12.6. Create dictionaries -Set-based x 1,393 ops/sec ±0.85% (60 runs sampled) -Regex-based x 1,798 ops/sec ±0.75% (61 runs sampled) -Trie-based (1st-gen) x 419 ops/sec ±1.35% (61 runs sampled) -Trie-based (2nd-gen) x 986 ops/sec ±0.77% (63 runs sampled) Done.
- deleted 8y ago[deleted]
- tpush 8y agoI wish gorhill would make a Safari content-blocker version of ublock. None of the existing blockers (who mostly just package existing block lists and charge money for it..) work as well as uBlock IME.
- radicaldreamer 8y agoThere's a fantastic fork/port available: https://safari-extensions.apple.com/details/?id=com.el1t.uBlock-3NU33NW2M3 https://safari-extensions.apple.com/details/?id=com.el1t.uBl... It's not a content-blocker version, but it's a port of Chrome version.
- bangonkeyboard 8y agoThis point release is broken [0], the maintainer has disappeared [1], and Safari will kill it shortly [2]. [0]: https://github.com/el1t/uBlock-Safari/issues/122 https://github.com/el1t/uBlock-Safari/issues/122 [1]: https://github.com/el1t/uBlock-Safari/issues/130 https://github.com/el1t/uBlock-Safari/issues/130 [2]: https://developer.apple.com/documentation/safariextensions https://developer.apple.com/documentation/safariextensions
- grawlinson 8y agoUnfortunately, all Safari releases going forward (12 onwards) are removing APIs that allow uBlock Origin to do what it does. Apple are basically neutering _all_ blockers, unfortunately. I don't know if they're planning on filling the void though.
- happybuy 8y agoThe reason these APIs are being removed are to improve the privacy of users. Apple recommends all adblock extensions now use the content blocking API which is superior from a user privacy perspective. When using the content blocker apis, the extension cannot view or read which web pages are visited. Prior extension APIs had full access to browsing history (which obviously can be easily abused). The content blocker API is different but does allow full featured and sophisticated adblockers. I know because I create one which is very efficient, effective and free - Magic Lasso Adblock (https://www.magiclasso.co/ https://www.magiclasso.co/)
- WeAreGoingIn 8y agoThe first plugin I install on a freshly installed system with Firefox is uBO. After that I harden the browser by changing stuff in about:config. Chrome has never been an option for us with privacy in focus. The guys behind uBO should get some price or something.
- _emacsomancer_ 8y agoWhat sorts of things do you change in about:config?
- WeAreGoingIn 8y agoThanks for asking. Many stuff is disabled by default, but it’s a moving target. There are some tutorials online to read. It depends on what the browser is used for. Some hardening breaks certain sites. Some stuff to look at: - dns-prefetch - geo - cookie - dom (disable, breaks sites) - browser.cache.disk - clipboard.events - media.peerconnection - healthreport - spoofRefererHeader Chrome doesn’t remove history when closed is a big issue.
- karrotwaltz 8y agoI've got this list in my favs, I think it was posted on HN a while ago: https://gist.github.com/0XDE57/fbd302cef7693e62c769 https://gist.github.com/0XDE57/fbd302cef7693e62c769 I had some problems with sendRefererHeader, so it can definitely break some websites
- WalterGR 8y agoit can definitely break some websites. That makes sense. Checking the Referer header is a quick and dirty way to implement cross-site request forgery (CSRF) protection.
- unicornporn 8y agoNot as extensive, but certainly more user friendly option: https://ffprofile.com/ https://ffprofile.com/
- 8y ago
- lvs 8y agoKeep on fighting the good fight, gorhill.
- aiNohY6g 8y agoThank you so much gorhill. So much, for making the web a better place.
- suyash 8y agoWhat is a good ad blocker like this for Safari?
- atombender 8y agoI use 1Blocker. It exists for both macOS and iOS. It uses Safari's native content blocking API, so it's supposedly fast. As far as I know, the developer is not engaged in any shady dealings with ad companies. The only downside is that it's not free.
- dawnerd 8y agoThe Dev did something shady on iOS by releasing a second version just because he split up the lists.
- gabll 8y agoHis argumentations don't seem shady to me: https://backstage.1blocker.com/say-hello-to-1blocker-x-8b55efe1ae36 https://backstage.1blocker.com/say-hello-to-1blocker-x-8b55e...
- fragebogen 8y agouBlock exists also for Safari, however you need to download it through the App Store these days. https://www.ublock.org/safari/ https://www.ublock.org/safari/
- Klover 8y agoThat’s not uBlock Origin, that’s the icky one. I use the AdGuard extension for desktop Safari, and the app for mobile Safari, which use the content blocking feature of Safari itself.
- fragebogen 8y agoMy bad, thanks for the clarification. As @heartbreak pointed out, this seems to be the real deal https://safari-extensions.apple.com/details/?id=com.el1t.uBlock-3NU33NW2M3 https://safari-extensions.apple.com/details/?id=com.el1t.uBl...
- amanzi 8y agoSince the last major Firefox update, I haven't needed to run an adblocker. I set Firefox to block trackers always (not just in private mode) and I hardly ever see ads, or I don't notice them at least.
- gtyras2mrs 8y agoDespite built in options for ad-block, uBlock Origin is still essential for me. There is too much junk on sites, poorly designed elements that take up half my screen, social media elements, video elements - I tend to block those elements freely.
- DDebbieDDowner 8y agoSorry to burst everyone's bubble, but in this test uBlock Origin failed miserably, to say the least. https://avlab.pl/test-web-browser-extensions-protection-against-malicious-software https://avlab.pl/test-web-browser-extensions-protection-agai...
- sysstemlord 8y agoSince when is uBlock an Anti-Virus? If you benchmark the latest Ferrari against a wooden boat for driving on water you will get the same results as this test.
- DDebbieDDowner 8y agoNone of the other browser extensions in the test are Anti-Viruses yet they seem to block fine many of the malware threats Furthermore, what is the purpose of Malvertising filter list by Disconnect, Malware Domain List, Malware domains, in uBlock Origin if they can't protect the user from malwares?
- gattilorenz 8y agoFair enough, uBlock Origin advertises itself as following (from the github page): uBlock Origin is NOT an "ad blocker": it is a wide-spectrum blocker -- which happens to be able to function as a mere "ad blocker". The default behavior of uBlock Origin when newly installed is to block ads, trackers and malware sites -- through EasyList, EasyPrivacy, Peter Lowe’s ad/tracking/malware servers, various lists of malware sites, and uBlock Origin's own filter lists. However, I assume that most people still use it mainly for blocking ads. And for that it is excellent.
- la_oveja 8y agoWhat. Everyone of them is an anti-virus extension except uBlock Origin: Avast, Avira, Bitdefender, CheckPoint SandBlast Agent, Malwarebytes, McAfee, Panda, Windows Defender,... All are extensions made to enhance the effectiveness of it's own security suite. uBlock is just a content-blocker.
- thefounder 8y agoI wonder how long will take until they ban/remove this as well using DCMA
- raverbashing 8y agoI've been having a lot of cosmetic filtering issues with UBlock lately, not sure if it's an issue with the lists or with UBO itself. Sites that load but stay "blank" until you disable filtering
- castis 8y agosome websites out there will detect that no ad code was allowed to run and then refuse to show you a page.
- grossdm 8y agoThis is widely known. It's also why uBlock replaces ad scripts with "neutered" scripts to make the page render anyway. It's good stuff!
- Zekio 8y agoThis type of issue is usually solved for me by going into uBlock Origins settings and pressing update for the blocking list
- grossdm 8y agoAre you using this list? Adblock Warning Removal List https://easylist-downloads.adblockplus.org/antiadblockfilters.txt https://easylist-downloads.adblockplus.org/antiadblockfilter...
- sundar4344 8y agoUBlock Origin is more than an ad-blocker. Some usecases other than being ad-blocker 1. Hide Quora notification icon 2. Hide YouTube notification icon 3. Hide stackoverflow questions you might be interested section(right bottom section) How do you use other than ad-blocker?
- saagarjha 8y agoIt’s really a content blocker, primarily used to blog ads.
- neuronic 8y ago4. Hide humongous Wikipedia donation element after having donated.
- LeonM 8y agoThis. The wikipedia page is completely broken on mobile devices during the fundraiser. (Text in the popup is so large that it becomes impossible to hit the close button). I have donated to wikipedia for the past 5 years, and will continue to do so. But the fundraiser banner is just terrible, and persists after you donated.
- lunchables 8y agoIt is really annoying to get that even after donating. I have never signed up for a wikipedia account (which, now that I think about it, is kind of amazing?) but if I had one, would the donation dialog disappear after donating? Maybe I will sign up to find out.
- lloeki 8y agoAt the very least for me it didn't last time I donated: the donation seems to be completely untied to your account.
- casefields 8y agoReminder: Wikipedia has Cancer. https://en.m.wikipedia.org/wiki/Wikipedia:Wikipedia_Signpost/2017-02-27/Op-ed https://en.m.wikipedia.org/wiki/Wikipedia:Wikipedia_Signpost...
- nathcd 8y agoOne third-party filter list for uBO that I absolutely love is Web Annoyances Ultralist: https://github.com/yourduskquibbles/webannoyances https://github.com/yourduskquibbles/webannoyances, for unsticking fixed headers, floating boxes, and elements like that. I also use uBO for injecting my own styles on pages, like adding an absolute timestamp to github: https://news.ycombinator.com/item?id=15743008 https://news.ycombinator.com/item?id=15743008
- hartator 8y agoDo you have weird bugs with it? I like the idea but I will be worried of having random bugs time to time that are more annoying than the annoyance the list try to remove.
- nathcd 8y agoI've never had any issues with it. (At least that I'm aware of - I block lots of stuff by default with uMatrix, so I usually assume breakage is due to that.) In case you're worried that it'll catch incorrect elements via generic selectors or the like, the list is almost entirely site-specific selectors (see [1]). The (much smaller) list of generic selectors can be found at [2]. [1] https://github.com/yourduskquibbles/webannoyances/blob/master/ultralist.txt https://github.com/yourduskquibbles/webannoyances/blob/maste... [2] https://github.com/yourduskquibbles/webannoyances/blob/master/filters/generic_filters.txt https://github.com/yourduskquibbles/webannoyances/blob/maste...
- metalliqaz 8y agohow does one go about finding lists like these?
- nathcd 8y agohmmmmm, IIRC I just found this one via DDG. This is the only third-party list I use. From a quick look-around, I just found https://filterlists.com/ https://filterlists.com/ though.
- vanderZwan 8y ago> The original prototype was to develop an idea I had about using jump indices in a TypedArray for quickly matching hostnames (or more generally strings)[1]. Once I had a working, un-optimized prototype, I realized I had ended up with something formally named a "trie": <https://en.wikipedia.org/wiki/Trie> https://en.wikipedia.org/wiki/Trie>, hence the name. I have no idea whether the implementation here or one resembling it has been done elsewhere. So I heavily experimented with squeezing performance out of a JS-based trie-implementation for LZString[0]. Back then some early experimentation suggested that using TypedArrays was likely to be slower than using objects with numerical keys, and for non-degenerate input using a trie based on plain arrays and indexOf calls was the fastest[1]. However, it's been a while since I looked at those numbers (and I suspect that with uBlock's use case look-up performance matters more than insertion performance, which makes it very different from LZString's). But it should be obvious that HNTrie's implementation[2] is something I'm very interested in ;). [0] https://github.com/pieroxy/lz-string/pull/98 https://github.com/pieroxy/lz-string/pull/98 [1] https://github.com/pieroxy/lz-string/blob/ba8988028d78962ebadee42cc6d4b17581605e2d/lz-string-unsafe.js https://github.com/pieroxy/lz-string/blob/ba8988028d78962eba... [2] https://github.com/gorhill/uBlock/blob/2a91a685ce3d2dae5d3c285cff1bc74a1982be74/src/js/hntrie.js https://github.com/gorhill/uBlock/blob/2a91a685ce3d2dae5d3c2...
- vanderZwan 8y agoAddendum: to clarify, with "non-degenerate input" I mean that for the vast majority of nodes in the resulting trie we have a handful of charCodes to search through at most. This holds true for most normal types of text. It is however trivial to create string that breaks this assumption: make one that features every legal UTF16 charCode. Throwing this at lzstring-unsafe.js will freeze it. So this could be another assumption that does not hold for uBlock's use case.
- kodablah 8y agoThe idea I had a year ago [0] was to bake the host names inside of WASM with hardcoded character lookups. You can build WASM from inside JS easily enough, or in other ways, and just ship hostnames.wasm with the product. Maybe I should revisit the idea with benchmarks. 0 - https://github.com/cretz/software-ideas/issues/68 https://github.com/cretz/software-ideas/issues/68
- __s 8y agoGood to see wat being used over bringing in emscripten baggage: https://github.com/gorhill/uBlock/tree/master/src/js/wasm https://github.com/gorhill/uBlock/tree/master/src/js/wasm
- vanderZwan 8y agoI wonder if this wouldn't be a good use-case for Walt. It's close enough to the metal to avoid bringing in unwanted baggage, but still a lot more convenient to write in than the .wat format. [0] https://github.com/ballercat/walt https://github.com/ballercat/walt
- andrepd 8y agoI've been using uBO in advanced (dynamic filtering) mode for a few weeks now. I strongly recommend everyone wary of privacy to start doing that now. It's surprisingly not so difficult at all!
- Twirrim 8y agoI'm a sucker for random benchmarks, and seeing there was a benchmark against the hostname-lookup stuff, I took a quick shot (2015 MacBook Pro, running High Sierra) Anyone know why regex performance on Safari is so diabolically bad? Safari 12.0.1 on OS X 10.13.6. Test 100 needles against 16 dictionaries of hostnames - Set-based x 3,149 ops/sec ±0.75% (59 runs sampled) - Regex-based x 281 ops/sec ±0.78% (61 runs sampled) - Trie-based (1st-gen) x 14,118 ops/sec ±1.66% (66 runs sampled) - Trie-based JS (2nd-gen) x 12,349 ops/sec ±0.58% (61 runs sampled) Chrome 70.0.3538.110 on OS X 10.13.6 64-bit. Test 100 needles against 16 dictionaries of hostnames - Set-based x 3,376 ops/sec ±1.95% (61 runs sampled) - Regex-based x 4,492 ops/sec ±1.66% (27 runs sampled) - Trie-based (1st-gen) x 9,431 ops/sec ±0.69% (51 runs sampled) - Trie-based JS (2nd-gen) x 8,627 ops/sec ±0.63% (47 runs sampled) - Trie-based WASM (2nd-gen) x 12,169 ops/sec ±0.58% (64 runs sampled) Done.
- wnevets 8y agothe most important browser extension
- jonssen 8y ago1.17.4 not functioning with Firefox 52.9.0 (32-bit) Reverting to 1.17.2 it works again.