-
Notifications
You must be signed in to change notification settings - Fork 81
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
Redirection fails for filters having *
in the host part
#572
Comments
https://github.com/gorhill/uBlock/wiki/Static-filter-syntax#redirect Domain with wildcard is not explicit enough. I think, uBO thinks destination domain is |
As pointed out in the documentation excerpted by @gwarser, not supported. |
Let's say I take Edit: Never mind, I was geo-blocked -- I can see the |
Sorry for my quick dismissal, giving more thoughts to this, uBO should still be able to extract a wildcard-less hostname from |
Related issue: - uBlockOrigin/uBlock-issues#572 Wildcards are now allowed in the hostname part of redirect filters. There will be an attempt to find the longest right-hand portion of the hostname with no wildcard. If no non-empty hostname can be extracted, `*` will be used.
I'm unable to verify whether the fix works or not at given specific case, as no so I've tried to redirect another request: when I've tried: Could you verify whether the fix works. As for the:
the are more such hostnames - a first is just above, and the others are:
And there is a bunch of requests grabbed from the logger: spoiler
|
Related commit: - fe0b7a0 Related feedback: - uBlockOrigin/uBlock-issues#572 (comment)
I made a mistake and tested only the one-wildcard case. This should work in the next dev build. |
It fixed the two-wildcard case: But now I've noticed another broken case, a one-wildcard case - which was already present even before the last fix, only that I didn't check it before: |
Ok, I overlooked that a wildcard could be positioned at another position than hostname label boundary. I will also fix for next dev build. |
Related commit: - fe0b7a0 Related feedback: - uBlockOrigin/uBlock-issues#572 (comment)
Fixed, all filters works now, even those from the 1st comment (as |
Now I've added GitLab mirror into any markdown documents that I've already written. The 🐱 will link to file location on GitHub, while 💊 will link onto GitLab instead. Filters update - [Misc] Add some rules for `Google` to prevent some async ping with `ei` parameter - [Test] Try prevent BingsuMaker script early for `Pantip`
Orginal polish issue: olegwukr/polish-privacy-filters#67
Orginal uassets issue: uBlockOrigin/uAssets#5360
The current issue perhaps somehow related to #568 and gorhill/uBlock#1597 and gorhill/uBlock#3590 not sure.
Prerequisites
Description
We were just trying to find a pure uBO solution (that doesn't need external solutions: (uBlockOrigin/uAssets#5360 (comment)) for anti-adblock for player.pl: olegwukr/polish-privacy-filters#67 and we succeeded (for Chrome-based browsers) but by the way discovered that some redirection filters with
*
does not work. We're not sure whether it's a bug in uBO or just a filter bug in domain syntax of the filter - perhaps only*.
works and no other characters are allowed in the domain of the filter if*
is used, like entity in static extended filters: https://github.com/gorhill/uBlock/wiki/Static-filter-syntax#entityA specific URL where the issue occurs
Example url:
https://player.pl/programy-online/kuchenne-rewolucje-odcinki,114
Steps to Reproduce
Filter 1:
||n-*-*.dcs.redcdn.pl/*/TVN-Adserver/*.mp4$media,redirect=noopmp3-0.1s,domain=player.pl
Filter 2:
||n-*.dcs.redcdn.pl/*/TVN-Adserver/*.mp4$media,redirect=noopmp3-0.1s,domain=player.pl
Filter 3:
||*.dcs.redcdn.pl/*/TVN-Adserver/*.mp4$media,redirect=noopmp3-0.1s,domain=player.pl
Filter 4:
||dcs.redcdn.pl/*/TVN-Adserver/*.mp4$media,redirect=noopmp3-0.1s,domain=player.pl
Expected behavior:
Filters 1 and 2 should work just like Filter 3 and 4.
Actual behavior:
Filters 1 and 2 not working, the part
n-*-*.
orn-*.
breaks the redirection.Your environment
Screenshoots:
Filters 1 and 2 (video not playing - an error showing up)
Filters 3 and 4 (video playing fine)
The text was updated successfully, but these errors were encountered: