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

Reverse lookup partially fails for a filter redirecting to empty media resource #1358

Closed
8 tasks done
Yuki2718 opened this issue Nov 23, 2020 · 4 comments
Closed
8 tasks done
Labels
bug Something isn't working fixed issue has been addressed

Comments

@Yuki2718
Copy link

Yuki2718 commented Nov 23, 2020

Prerequisites

  • I verified that this is not a filter issue
  • This is not a support issue or a question
  • I performed a cursory search of the issue tracker to avoid opening a duplicate issue
    • Your issue may already be reported.
  • I tried to reproduce the issue when...
    • uBlock Origin is the only extension
    • uBlock Origin with default lists/settings
    • using a new, unmodified browser profile
  • I am running the latest version of uBlock Origin
  • I checked the documentation to understand that the issue I report is not a normal behavior

Description

Reverse lookup of filter lists on the logger fails for a filter redirecting to media resource - in the example below it succeeds for ||static.twincdn.com^$media,redirect-rule=noopmp3-0.1s but fails for ||static.twincdn.com^$media. No such problem for ||google-analytics.com/analytics.js redirected to google-analytics.com/analytics.js on the same page (EDIT: maybe not, as it shows Peter Lowe's as Filter list which has the exact blocking filter - so maybe blocking part of $redirect was not counted?).

A specific URL where the issue occurs

[NSFW] https://www.pornohirsch.net/film/blonde-stiefschwester-laesst-sich-hart-ficken-45035/

Steps to Reproduce

  1. Visit URL with default setup and open the logger
  2. Close video-overlay (or add pornohirsch.net##.vjs-overlay from the beginning)
  3. Play the video and see the logger

Expected behavior:

It shows uBlock filters as Filter list.

Actual behavior:

"Static filter could not be found in any of the currently enabled filter lists"

redirect-nofilterfound

Your environment

  • uBlock Origin version: 1.31.0
  • Browser Name and version: Firefox 83.0
  • Operating System and version: Windows 10
@uBlock-user uBlock-user added the bug Something isn't working label Nov 23, 2020
@gorhill
Copy link
Member

gorhill commented Nov 23, 2020

Do I need to add ||static.twincdn.com^$media? If so, how did you add it? Did you add it through the logger or directly in "My filters"?

@Yuki2718
Copy link
Author

Yuki2718 commented Nov 23, 2020

@gorhill uBlock filters has ||static.twincdn.com^$media,redirect=noopmp3-0.1s. I mean, redirect= and not redirect-rule= (but not complaining about that logger shows as redirect-rule - my issue is its blocking part is ignored on the logger in case of media. Apparently no such issue for script).

@gorhill
Copy link
Member

gorhill commented Nov 23, 2020

Ok I can reproduce -- investigating.

@gorhill
Copy link
Member

gorhill commented Nov 23, 2020

The issue is that without a redirect option, the same block filter is compiled at this line, while with the redirect option the block filter counterpart is compiled at a different point, using a different internal representation.

gorhill added a commit to gorhill/uBlock that referenced this issue Nov 25, 2020
@uBlock-user uBlock-user added the fixed issue has been addressed label Nov 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working fixed issue has been addressed
Projects
None yet
Development

No branches or pull requests

3 participants