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

specific-generic cosmetic filter is not disabled by generichide #1858

Closed
8 tasks done
Yuki2718 opened this issue Dec 6, 2021 · 7 comments
Closed
8 tasks done

specific-generic cosmetic filter is not disabled by generichide #1858

Yuki2718 opened this issue Dec 6, 2021 · 7 comments
Labels
bug Something isn't working fixed issue has been addressed

Comments

@Yuki2718
Copy link

Yuki2718 commented Dec 6, 2021

Prerequisites

I tried to reproduce the issue when...

  • uBO is the only extension
  • uBO with default lists/settings
  • using a new, unmodified browser profile

Description

Related issue: uBlockOrigin/uAssets#10336 (comment)
At the time *##.AdSense and @@||uploadbank.com^$ghide were in uBlock filters and the former triggered anti-adb.

A specific URL where the issue occurs

https://www.uploadbank.com/wdxx40hx9g0e

Steps to Reproduce

  1. Add *##.AdSense and uploadbank.com#@#+js(acis, decodeURIComponent, return"%") to My filters and visit the URL
  2. See anti-adb is triggered

Expected behavior

@@||uploadbank.com^$ghide should disable specific-generic cosmetic filters as per wiki. TBH otherwise specific-generic is too risky to use.

Actual behavior

Not disabled by $ghide.

uBlock Origin version

1.39.2

Browser name and version

94.0.2 (UA changed to Mozilla/5.0 (Android 11; Mobile; rv:93.0) Gecko/93.0 Firefox/93.0)

Operating System and version

Windows 10

@gorhill
Copy link
Member

gorhill commented Dec 6, 2021

I cannot reproduce with this minimal steps to repro:

  • To "My filters", add *##body
  • Navigate to https://example.com/
  • Result: page is blank
  • To "My filters", add @@||example.com^$ghide
  • Navigate to https://example.com/
  • Result: page renders fine

@gorhill
Copy link
Member

gorhill commented Dec 6, 2021

I can reproduce the issue, it seems some cached value regarding whether generic cosmetic filtering is disabled or not is the issue.

@Yuki2718
Copy link
Author

Yuki2718 commented Dec 6, 2021

You're right, I have to check what was wrong on my side.

@Yuki2718
Copy link
Author

Yuki2718 commented Dec 6, 2021

@gorhill Can you check with the URL I posted? Here you see ghide and *##.AdSense are both applied:

Screenshot

uploadbank

Update: missed your comment

I can reproduce the issue, it seems some cached value regarding whether generic cosmetic filtering is disabled or not is the issue.

@gorhill
Copy link
Member

gorhill commented Dec 6, 2021

Ok it's because the page creates an about:blank frame and uBO checks whether generic cosmetic is disabled in about:blank, which it is not. uBO needs to replace about:blank with the URL of the owner of that blank frame.

gorhill added a commit to gorhill/uBlock that referenced this issue Dec 6, 2021
@gwarser gwarser added the bug Something isn't working label Dec 6, 2021
@gwarser

This comment has been minimized.

@gwarser gwarser added the fixed issue has been addressed label Dec 6, 2021
@gwarser gwarser closed this as completed Dec 6, 2021
@gorhill
Copy link
Member

gorhill commented Dec 6, 2021

ghide prevents implicit display: none !important, it does not touch explicit styling.

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