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

uBlock doesn't understand ABP's Redirect flag. #1183

Closed
ghost opened this issue Jan 7, 2016 · 15 comments
Closed

uBlock doesn't understand ABP's Redirect flag. #1183

ghost opened this issue Jan 7, 2016 · 15 comments
Labels

Comments

@ghost
Copy link

ghost commented Jan 7, 2016

[Adblock Plus 2.0]
! Title: Please update.
! Expires: 1 days
! Redirect: http://xxxxxxxx.txt

Expected Result:
uBlock update URL to "!Redirect" one like Adblock does.

Actual Result:
uBlock doesn't update URL to new one.

@gorhill
Copy link
Owner

gorhill commented Jan 7, 2016

You have a concrete case?

@ghost
Copy link
Author

ghost commented Jan 7, 2016

I can't understand what "concrete case" is, but here's more detailed explanation:

https://adblockplus.org/en/filters

! Redirect: http://example.com/list.txt

This comment indicates that the filter list has moved to a new download address. Adblock Plus will ignore any file contents beyond that comment and immediately try downloading from the new address. In case of success the address of the filter list will be updated in the settings. This comment is ignored if the new address is the same as the current address, meaning that it can be used to enforce the "canonical" address of the filter list.

[Adblock Plus 2.0]

NoMercy's SSL list is moving to HTTP.

@ghost
Copy link
Author

ghost commented Jan 7, 2016

Also, ABP can handle 301/302 list redirection. How uBlock handle them?

http://other.list/ "HTTP 301. go to https://other.list"
https://other.list/ "HTTP 200. Here's your file." <--- ABP will update list URL to this one

@gorhill
Copy link
Owner

gorhill commented Jan 7, 2016

I can't understand what "concrete case" is

It means I won't bother investing my free time implementing something for which there is no real world occurrence.

@Havokdan
Copy link

Havokdan commented Jan 7, 2016

Well, I don't think it's the case to open a new ticket, but it is possible the uBlock go straight to the target site, for example, I am Brazilian, I visit the site, www.uol.com.br which is a site of news, information, and etc all link I click there the uBlock now blocks with resource usage which I imagine is this redirect that has been added in the latest version What I want to know is whether it is possible to go straight to the target site, ignoring in this case, the address "www.click.uol.com.br"e going straight to the desired page, without stopping on uBlock page, as in the image:

http://i.imgur.com/pyPthhL.png

I'm sorry in advance, don't speak English, although it can understand some of what is written by you, I can't write well, so I used an online translator.

@aimtsou
Copy link

aimtsou commented Jan 7, 2016

@gorhill: He means that he should be redirected instead of allowing temporarily due to the script. By the way, a question I have is: The redirect feature is an automatic one(bypass the redirection) and when does it show the ublock0 page.

I tried the case and I see the redirect/tracking part before the real news page. But my Ublock0 does not block that and does not show the parameters. Which are your settings?

@Havokdan
Copy link

Havokdan commented Jan 7, 2016

My settings is:

http://i.imgur.com/oX1Pt2D.png

In Windows 10 x64 (Ublock & Umatrix in Chrome, Opera and Firefox)

@gorhill
Copy link
Owner

gorhill commented Jan 7, 2016

@Havokdan , @aimtsou

Let's keep issues separate please, otherwise this drowns the original issue in noise. Original issue is "ABP Redirect directive in filter lists".

What you are talking about is uBO's strict blocking -- a completely different, unrelated issue. See #973. What you are asking is not possible in practice, there is no way uBO will decide for you if whatever URL(s) has been parsed from the original URL should be loaded without asking the user first. You will have to click whatever URL is in there (there can be many), this implies informed consent, something uBO can't do for you.

@anewuser
Copy link
Contributor

anewuser commented Jan 7, 2016

@Havokdan Use Redirector (Opera version here):

Redirector screenshot

@Havokdan
Copy link

Havokdan commented Jan 7, 2016

Thanks, i will try.

@gorhill gorhill changed the title uBlock doesn't understand Redirect flag. uBlock doesn't understand ABP's Redirect flag. Jan 8, 2016
@lewisje
Copy link

lewisje commented Jan 9, 2016

I was honestly surprised that the Redirect command wasn't understood; I'm thinking about opening an issue now for a similar command that I have found wasn't understood (but the fact that uBlock Origin doesn't enforce it makes it easier on list authors).

EDIT: After checking the codebase, it looks like uBlock Origin does calculate its own checksums to check for obsolescence of some lists, and for obsolescence and corruption of important lists that ship with the extension, but I still don't see where the ABP command itself is ever used.

@maxxyme
Copy link

maxxyme commented Mar 11, 2016

NoMercy's SSL list is moving to HTTP.

I think that was the concrete case. But I can't find this list.
Found some discussion about it here: https://adblockplus.org/forum/viewtopic.php?t=29330
Re-installed Adblock Plus (last v.1.11) but didn't find this list in the already built-in suggestions.

Edit: it has already been mentioned ealier in an issue for the old uBlock: uBlock-LLC/uBlock#769
as well as on adstomper bug tracker (see history for the "new" URLs - at that time): https://bitbucket.org/adstomper/adblockedge/issues/78

@SysadminJeroen
Copy link

SysadminJeroen commented Apr 15, 2016

I just moved a small list of maybe 6 PCs to a new location, this feature would be appreciated to move all the PCs to the new location.'

Edit: As clarification, with new location I mean a new URL.

@fuzzyroddis
Copy link

@gorhill I used ! Redirect: to move my own filter list from example.com to cdn.example.com
I understand that there are more pressing issues however. Traffic costs on example are much higher for me but worth it as it's much much better latency and speeds. I use cdn.example.com for bulk bandwidth where it's much cheaper and suited for something that updates in the background.

@lewisje
Copy link

lewisje commented Apr 24, 2016

If you can set HTTP headers on your old domain, try sending a 301 Moved Permanently response whenever the old lists are requested; I'm not sure whether uBlock Origin will update the list URLs after receiving that header, but at least you'll only get the overhead of the requests and not the overhead of the response bodies.

You don't necessarily need to be able to modify the .htaccess file in Apache, or a server config in NGINX; if your old domain allows server-side scripts, you could set up such a script to handle unknown URL requests and set the appropriate headers for those specific URLs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

8 participants