This repository was archived by the owner on Sep 9, 2022. It is now read-only.
Commit d1e1ca1
committed
Performance and memory related changes
1. Special treatment for hostname-anchored (`||`) filters having wildcard characters. These filters are categorized into three types. The purpose is to convert regex based filter internally into plain string based filters.
- Filters having a single occurrence of pattern `^*` after the hostname and no other wildcard character on another side of this pattern.
||*.cloudfront.net^*F2P_SideBar_Banner_EN.jpg
||*2mdn.net^*/1x1image.jpg$image
||2mdn.*^*/1x1image.jpg$image
- Filters having a single occurrence of wildcard character `*` after the hostname and no other wildcard character on another side of it.
||*.cloudfront.net/wp-content/*F2P_SideBar_Banner_EN.jpg
||cloudfront.net/wp-content/*F2P_SideBar_Banner_EN.jpg
||www.google.*/aclk?*^/am=&adurl=
||i.com.com/wp-content/*F2P_SideBar_Banner_EN.jpg
- Other filters
||cloud*.net^$third-party
@@||doubleclick.net/adi/mlb.mlb/*^free_agent_tracker_12^$subdocument,domain=mlb.com
2. Now hostname-anchored (`||`) filters matches hostname in URL accurately.
||*-aaa.net^$third-party
3. Filters having a single occurrence of wildcard character `*` converted internally into plain string based filters.
@@/cdn-cgi/pe/bag2?*googleadservices.com%2Fpagead%2Fconversion.js$xmlhttprequest,domain=ethica.net.au|factom.org|gogoonhold.com.au
/cdn-cgi/pe/bag2?r*.qualitypublishers.com
4. Using singleton object in case of any match URL filter.
$script,third-party,domain=0dt.net|123videos.tv
5. Ignore token if it is preceded by `*` characters in Token generate logic1 parent d996541 commit d1e1ca1
File tree
4 files changed
+349
-59
lines changed- platform/chromium
- src/js
4 files changed
+349
-59
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
95 | 95 | | |
96 | 96 | | |
97 | 97 | | |
98 | | - | |
| 98 | + | |
99 | 99 | | |
100 | 100 | | |
101 | 101 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
91 | 91 | | |
92 | 92 | | |
93 | 93 | | |
94 | | - | |
95 | | - | |
| 94 | + | |
| 95 | + | |
96 | 96 | | |
97 | 97 | | |
98 | 98 | | |
| |||
0 commit comments