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

$uritransform sometimes not working. #3125

Closed
8 of 9 tasks
Iz-zzzzz opened this issue Feb 15, 2024 · 2 comments
Closed
8 of 9 tasks

$uritransform sometimes not working. #3125

Iz-zzzzz opened this issue Feb 15, 2024 · 2 comments
Labels
bug Something isn't working fixed issue has been addressed

Comments

@Iz-zzzzz
Copy link

Iz-zzzzz commented Feb 15, 2024

Prerequisites

  • I verified that this is not a filter list issue. Report any issues with filter lists or broken website functionality in the uAssets issue tracker.
  • This is NOT a YouTube, Facebook or Twitch report. These sites MUST be reported by clicking their respective links.
  • This is not a support issue or a question. For support, questions, or help, visit /r/uBlockOrigin.
  • I performed a cursory search of the issue tracker to avoid opening a duplicate issue.
  • The issue is not present after disabling uBO in the browser.
  • I checked the documentation to understand that the issue I am reporting is not normal behavior.

I tried to reproduce the issue when...

  • uBO is the only extension.
  • uBO uses default lists and settings.
  • using a new, unmodified browser profile.

Description

From this #3084
Its seem like I can replace or remove any parts of url with $uritransform, so I create this rule

||pantip.com^$doc,uritransform=/#lead:.*//

to remove tracking part of

https://pantip.com/topic/41624586#lead:related:6B9mGrzkxFdzAeuBEWJhXs:6:https://pantip.com/topic/42521369

(example url) but it works when there is only this uritransform rule enable. When I enable another uritransform rule:

*$uritransform=/\?fbclid=//

Both uritransform rules stop working, and uBO doesn't mark any rules as invalid too. If the second rule is invalid, the first rule should still working.

A specific URL where the issue occurs.

`https://pantip.com/topic/41624586#lead:related:6B9mGrzkxFdzAeuBEWJhXs:6:https://pantip.com/topic/42521369`

Steps to Reproduce

  1. Create test.txt file in Desktop
  2. Allow uBO to access to file URLs
    image
  3. Import test.txt to uBO custom filters and add file:/// in trustedListPrefixes to make sure this filter have enough permission.
    image
  4. Disable all filters beside test.txt to make sure test.txt rules don't conflict with other rules.
  5. Add ||pantip.com^$doc,uritransform=/#lead:.*// rule to test.txt
  6. Add *$uritransform=/\?fbclid=// rule to test.txt
  7. Save test.txt
  8. Click update filter
    image
  9. go to https://pantip.com/topic/41624586#lead:related:6B9mGrzkxFdzAeuBEWJhXs:6:https://pantip.com/topic/42521369 site
  10. see ||pantip.com^$doc,uritransform=/#lead:.*// doesn't work

Expected behavior

  1. ||pantip.com^$doc,uritransform=/#lead:.*// should work even there is *$uritransform=/\?fbclid=// rule.
  2. tracking part of url should be removed and remain only https://pantip.com/topic/41624586.

Actual behavior

||pantip.com^$doc,uritransform=/#lead:.*// doesn't work and browser go to https://pantip.com/topic/41624586#lead:related:6B9mGrzkxFdzAeuBEWJhXs:6:https://pantip.com/topic/42521369 when there is *$uritransform=/\?fbclid=// rule.

uBO version

1.55.1rc4

Browser name and version

Brave Browser Version 1.62.162 Chromium: 121.0.6167.164 (Official Build) (64-bit)

Operating System and version

Windows 11 Education 22H2

@gwarser gwarser added the bug Something isn't working label Feb 15, 2024
@gwarser
Copy link

gwarser commented Feb 15, 2024

Works when the second filter does not match.

@Iz-zzzzz
Copy link
Author

Thank you (●'◡'●)

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

2 participants