Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: lib/content/snippets.js

Issue 29828604: Issue 6790 - Implement uabinject-defuser snippet (Closed) Base URL: https://hg.adblockplus.org/adblockpluscore/
Patch Set: Rebase on patch #29829569 Created July 13, 2018, 2:34 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * This file is part of Adblock Plus <https://adblockplus.org/>, 2 * This file is part of Adblock Plus <https://adblockplus.org/>,
3 * Copyright (C) 2006-present eyeo GmbH 3 * Copyright (C) 2006-present eyeo GmbH
4 * 4 *
5 * Adblock Plus is free software: you can redistribute it and/or modify 5 * Adblock Plus is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as 6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
8 * 8 *
9 * Adblock Plus is distributed in the hope that it will be useful, 9 * Adblock Plus is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 } 65 }
66 66
67 exports.log = log; 67 exports.log = log;
68 68
69 function trace(...args) 69 function trace(...args)
70 { 70 {
71 log(...args); 71 log(...args);
72 } 72 }
73 73
74 exports.trace = makeInjector(trace, log); 74 exports.trace = makeInjector(trace, log);
75
76 // This is an implementation of the uabinject-defuser technique used by uBlock
77 // Origin
78 // https://github.com/uBlockOrigin/uAssets/blob/c091f861b63cd2254b8e9e4628f6bdcd 89d43caa/filters/resources.txt#L640
79 function uabinjectDefuser()
80 {
81 window.trckd = true;
82 window.uabpdl = true;
83 window.uabInject = true;
84 window.uabDetect = true;
85 }
86
87 exports["uabinject-defuser"] = makeInjector(uabinjectDefuser);
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld