From 845ea70cac05f7a07767b6faa7f752bed4a54f06 Mon Sep 17 00:00:00 2001 From: iam-py-test <84232764+iam-py-test@users.noreply.github.com> Date: Sun, 30 Jan 2022 11:38:28 -0500 Subject: [PATCH] Fix https://github.com/ClearURLs/Rules/issues/30 --- ClearURLs for uBo/compile.py | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/ClearURLs for uBo/compile.py b/ClearURLs for uBo/compile.py index a90b03cce..8ffdd3801 100644 --- a/ClearURLs for uBo/compile.py +++ b/ClearURLs for uBo/compile.py @@ -34,7 +34,7 @@ HEAD = """\ ! Homepage: https://github.com/DandelionSprout/adfilt/discussions/163 ! Description: Want to use ClearURLs' tracking protection without installing another extension? This list is a (unofficial) version of the ClearURLs rules, designed for use in uBlock Origin and AdGuard ! Last updated: {date} -! Script last updated: 2/1/2021 +! Script last updated: 30/1/2022 ! Expires: 1 day ! Licence: https://github.com/DandelionSprout/adfilt/blob/master/LICENSE.md ! Note: This was based off of https://gist.github.com/rusty-snake/5cd83a87d680ecbd03e79a1a06758207, which is based off of https://github.com/ClearURLs/Rules. The maintainers of Adfilt (DandelionSprout and iam-py-test, and contributors) have made some modifications as to keep it up-to-date with the source and to fix issues @@ -72,6 +72,15 @@ KNOWN_BAD_FILTERS = [ "||walmart.$removeparam=wl13", ] +ALLOWLIST = """ +! This is an allowlist added by the adflit maintainers +@@||tix.axs.com^$removeparam=utm_campaign +@@||tix.axs.com^$removeparam=utm_content +@@||tix.axs.com^$removeparam=utm_medium +@@||tix.axs.com^$removeparam=utm_source +@@||tix.axs.com^$removeparam=utm_term +""" + def normalize_url_pattern(url_pattern: str) -> str: # No need for protocol and subdomain @@ -255,7 +264,7 @@ def main() -> int: filterlist.write("@@$removeparam,domain={0}".format(exception) + "\n") else: raise ValueError - + filterlist.write(ALLOWLIST) return 0