Ublock: Spurious redirect conflicts with HTTPS Everywhere

Created on 24 Mar 2018  路  16Comments  路  Source: gorhill/uBlock

HTTPS Everywhere 2018.2.26 dont work longer on chrome - uBlock, block it > options?

All 16 comments

For me it seems it's working as intended , both extensions
try force reloading the page Ctrl+Shift+R

Got a problem with them as well.
HTTPS Everywhere is currently trying to redirect https://www.google-analytics.com/analytics.js and I suppose uBlock does the same. Does anyone know what filter takes care of that on uBlock?
Error is as it follows:
Warning:
This extension failed to redirect a network request to https://www.google-analytics.com/analytics.js because another extension (uBlock Origin) redirected it to chrome-extension://cjpalhdlnbpafiamejdnhcphjbkeiagm/web_accessible_resources/59fb24a2d12455d15bea20980e8a6801.javascript?secret=k3w31pnoge0l.
Is it the same error you got @Vidarius?

This is an expected result. uBlock redirects google analytics to a stub script that stops some sites from breaking. Gorhill talks more about it in this comment.

This clash results in a highly visible ! error indicator in the top right corner of Chrome.

In practicals land, for those of us who use both uBlock Origin and HTTPS Everywhere, what can we do to silence this error?

I suppose the order of installation matters, this is the case where HTTPS Everywhere is installed before uBlock Origin:

This extension failed to redirect a network request to 
chrome-extension://cjpalhdlnbpafiamejdnhcphjbkeiagm/web_accessible_resources/d363525161c56887ceebe5e72ed4ef31.javascript?secret=ggd92ckr1pfj 
because another extension (HTTPS Everywhere) redirected it to 
https://c.amazon-adsystem.com/aax2/amzn_ads.js.

@gorhill,

Do you recommend I and others stop using HTTP Everywhere?

Back in the day it served a real purpose, for example YouTube used to prefer plain over SSL. But here in 2018 that probably is not the case? Is it more hinderance than benefit?

I, for one, would definitely recommend against using this extension.

You already stated the reason. HTTP/HTTPS "dual mode" is hardly a thing nowadays. And, again, if the server does not provide a secure connection the extension is pointless in any way.
And all of this for exposing user privacy by storing per URL settings in plain text? No, thanks.

I won't tell people what to do. I will tell what is happening, and from this people can decide for themselves. One of two cases can happen:

The error message is a result of two extensions trying to redirect the same network request: the Chrome/WebExtensions API allows only one extension to redirect a network request. Extensions are not made aware that their redirection failed. The reason for this is probably technical: conceptually extensions execute in parallel.

uBO redirect wins

Benign.

Typically the error message _"This extension failed to redirect a network request..."_ will be with HTTPS-Everywhere in the Extensions page (as reported in opening comment).

This won't affect the purpose of HTTPS-Everywhere -- because no network requests is fired to the outside world.

HTTPS-Everywhere redirect wins

Serious Benign.

Typically the error message _"This extension failed to redirect a network request..."_ will be with uBlock Origin in the Extensions page.

This will prevent uBO from redirecting the network request to a local neutered resource, meaning a network request which was meant meant to be blocked by uBO would no longer be blocked. uBO won't be able to redirect the original http: network request, because this one will be redirected by HTTPS-Everywhere to a secure https: connection. However, uBO will properly redirect the https: request to its local neutered resource, because of course HTTPS-Everywhere won't touch this one.

Considerations

The order in which the extensions were installed is what decide which extension will redirect first (I can't remember the order the last one installed wins -- thanks @Bisaloo) -- so this means by re-installing one or the other you could move from the "serious" to the "benign" case. So mainly either ways all work as expected except that you will have to tolerate the warnings in the Extensions page.

When a secure page (https) tries to pull a script from an unsecure location (http), the browser will refuse, mixed active content has been forbidden by browsers since quite a while now. So in that case, HTTPS-Everywhere is not really needed.

Why is this error more widely reported now? I have no clue, uBO has been redirecting to neutered resources since a very long time now (see #1170). Somebody on HTTPS-Everywhere's issue tracker pointed out that something related to extension error was fixed in Chrome 65.

About the order in which you need to install extensions to choose which one redirects first:

Only one extension is allowed to redirect a request or modify a header at a time. If more than one extension attempts to modify the request, the most recently installed extension wins and all others are ignored. An extension is not notified if its instruction to modify or redirect has been ignored.

Source: https://developer.chrome.com/extensions/webRequest

I corrected my assessment above. TL;DR: it's benign either way -- uBO will properly redirect to the local neutered resource. This may happen before or after HTTPS-Everywhere translate to https:, either ways the end result is that the network request will be handled by uBO as expected.

I have exactly the same problem as Igor described in https://github.com/gorhill/uBlock/issues/3639#issuecomment-375915949

uBlock conflicts with HTTPS everywhere to redirect https://www.google-analytics.com/analytics.js

Same problem with ublock in combo with HTTPS Everywhere. I have had both installed for a long time, but this didn't start occurring until recently (maybe a couple of weeks ago). I am getting an extension error for ublock. Details if it helps:

This extension failed to redirect a network request to chrome-extension://cjpalhdlnbpafiamejdnhcphjbkeiagm/web_accessible_resources/f6f25816c1c5ce3d465f4cd083539931.javascript?secret=sxbickgppwm9 because another extension (HTTPS Everywhere) redirected it to https://widgets.outbrain.com/outbrain.js.

Locking due to pointless "me too" noise.

Consider starring https://bugs.chromium.org/p/chromium/issues/detail?id=111700#c31 if you want this to be fixed.

Was this page helpful?
0 / 5 - 0 ratings