diff --git a/.editorconfig b/.editorconfig
index 1ccf04d6210d..d677601d7011 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -9,4 +9,7 @@ charset = utf-8
[src/chrome/content/rules/*.xml]
indent_style = tab
-indent_size = 4
\ No newline at end of file
+indent_size = 4
+
+[*.js]
+indent_size = 2
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 1a5333975602..49ad1f5556df 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -4,7 +4,7 @@ Welcome, and thank you for your interest in contributing to HTTPS Everywhere! HT
One of the things that makes it easy to contribute to HTTPS Everywhere is that you don't have to be a coder to contribute. That's because HTTPS Everywhere's most important component is the list of rules that tell it when it can request a website over HTTPS. These rules are just XML files that contain regular expressions, so if you can write XML and simple regexes, you can help us add rules and increase HTTPS Everywhere's coverage. No coding skills necessary!
-If you want to have the greatest impact, however, you can help be a ruleset maintainer. Ruleset maintainers are volunteers who examine rulesets contributed by others and work with them to ensure that these rulesets work properly and are styled correctly before they're merged in. While we currently have a couple of extremely dedicated and extremely proficient ruleset maintainers, the backlog of sites to add to HTTPS Everywhere just keeps growing, and they need help! If this sounds interesting to you, please contact us at https-everywhere-rules-owner [at] eff <dot> org.
+If you want to have the greatest impact, however, you can help be a ruleset maintainer. Ruleset maintainers are trusted volunteers who examine rulesets contributed by others and work with them to ensure that these rulesets work properly and are styled correctly before they're merged in. While we currently have a couple of extremely dedicated and extremely proficient ruleset maintainers, the backlog of sites to add to HTTPS Everywhere just keeps growing, and they need help! If you would like to volunteer to become one, the best thing to do is to build trust in your work by monitoring the repository, contributing pull requests, and commenting on issues that interest you. Then you can contact us at https-everywhere-rules-owner [at] eff <dot> org expressing your interest in helping out.
If you get stuck we have two publicly-archived mailing lists: the https-everywhere list (https://lists.eff.org/mailman/listinfo/https-everywhere) is for discussing the project as a whole, and the https-everywhere-rulesets list (https://lists.eff.org/mailman/listinfo/https-everywhere-rules) is for discussing the `rulesets` and their contents, including patches and git pull requests.
@@ -19,7 +19,7 @@ There are several main areas of development on HTTPS Everywhere: the rulesets, t
The rulesets can be found in the [`rules`](rules) top-level path and include all the rules for redirecting individual sites to HTTPS. These are written in XML. If you want to get started contributing to HTTPS Everywhere, we recommend starting here.
-The core codebase consists of the code that performs the redirects, the UI, logging code, the decentralized SSL observatory code, and ruleset loading, and is written in JavaScript. It is divided into two separate extensions. One is based on the `XPCOM` API used by Mozilla Firefox (soon to be deprecated, located in the [`src`](src) top-level path), and the other is based on the `WebExtensions` API (located in [`chromium`](chromium)), first developed in Google's Chromium browser.
+The core codebase consists of the code that performs the redirects, the UI, logging code, and ruleset loading. This encompasses all code delivered with the extension itself that is *not* a ruleset. It is written in JavaScript, using the `WebExtensions` API (located in [`chromium`](chromium)) on all supported browsers. In Firefox, this extension is wrapped in a thin `XPCOM` layer for the purposes of migrating settings, located in [`src`](src), which will soon be deprecated.
The utilities ([`utils`](utils) top-level path) include scripts that build the extension, sanitize and perform normalization on rulesets, simplify rules, and help label GitHub issues. Historically, these utilities have been written in Python. Many of the newer utilities are written in JavaScript, and are meant to be run in node. Some of the wrappers for these utilities are in shell scripts.
@@ -76,7 +76,7 @@ This would create `Example.com.xml`, which you could then take a look at and edi
## Minimum Requirements for a Ruleset PR
-There are several volunteers to HTTPS Everywhere who have graciously dedicated their time to look at the `ruleset` contributions and work with contributors to ensure quality of the pull requests before merging. It is typical for there to be several back-and-fourth communications with these `ruleset` maintainers before a PR is in a good shape to merge. Please be patient and respectful, the maintainers are donating their time for no benefit other than the satisfaction of making the web more secure. They are under no obligation to merge your request, and may reject it if it is impossible to ensure quality.
+There are several volunteers to HTTPS Everywhere who have graciously dedicated their time to look at the `ruleset` contributions and work with contributors to ensure quality of the pull requests before merging. It is typical for there to be several back-and-forth communications with these `ruleset` maintainers before a PR is in a good shape to merge. Please be patient and respectful, the maintainers are donating their time for no benefit other than the satisfaction of making the web more secure. They are under no obligation to merge your request, and may reject it if it is impossible to ensure quality. You can identify these volunteers by looking for the "Collaborator" identifier in their comments on HTTPS Everywhere issues and pull requests.
In the back-and-fourth process of getting the `ruleset` in good shape, there may be many commits made. It is this project's convention to squash-and-merge these commits into a single commit before merging into the project. If your commits are cryptographically signed, we may ask you to squash the commits yourself in order to preserve this signature. Otherwise, we may squash them ourselves before merging.
@@ -314,6 +314,8 @@ Officially supported browsers:
We also informally support Opera browser, but do not have tooling around testing Opera. Firefox ESR is supported because this is what the Tor Browser, which includes HTTPS Everywhere, is built upon. For the test commands, refer to [README.md](README.md).
+The current extension maintainer is @Hainish. You can tag him for PRs which involve the core codebase.
+
Several of our utilities and our full test suite is written in Python. Eventually we would like the whole codebase to be standardized as JavaScript. If you are so inclined, it would be helpful to rewrite the tooling and tests into JavaScript while maintaining the functionality.
* * *
diff --git a/chromium/.eslintrc.json b/chromium/.eslintrc.json
index cf42849defba..172f709bdcd9 100644
--- a/chromium/.eslintrc.json
+++ b/chromium/.eslintrc.json
@@ -6,9 +6,11 @@
"node": true,
"webextensions": true
},
-
"parserOptions": {
"ecmaVersion": 2017,
"sourceType": "script"
+ },
+ "rules": {
+ "indent": [2, 2]
}
}
diff --git a/chromium/background.js b/chromium/background.js
index 1e28a4f8c534..79bf1274df81 100644
--- a/chromium/background.js
+++ b/chromium/background.js
@@ -55,31 +55,42 @@ var switchPlannerEnabledFor = {};
// rw / nrw stand for "rewritten" versus "not rewritten"
var switchPlannerInfo = {};
-// Is HTTPSe enabled, or has it been manually disabled by the user?
+/**
+ * Load preferences. Structure is:
+ * {
+ * httpNowhere: Boolean,
+ * showCounter: Boolean,
+ * isExtensionEnabled: Boolean
+ * }
+ */
+var httpNowhereOn = false;
+var showCounter = true;
var isExtensionEnabled = true;
-storage.get({globalEnabled: true}, function(item) {
- isExtensionEnabled = item.globalEnabled;
- updateState();
-});
-// Load prefs about whether http nowhere is on. Structure is:
-// { httpNowhere: true/false }
-var httpNowhereOn = false;
-storage.get({httpNowhere: false}, function(item) {
+storage.get({
+ httpNowhere: false,
+ showCounter: true,
+ globalEnabled: true
+}, function(item) {
httpNowhereOn = item.httpNowhere;
+ showCounter = item.showCounter;
+ isExtensionEnabled = item.globalEnabled;
updateState();
});
chrome.storage.onChanged.addListener(function(changes, areaName) {
if (areaName === 'sync' || areaName === 'local') {
- for (var key in changes) {
- if (key === 'httpNowhere') {
- httpNowhereOn = changes[key].newValue;
- updateState();
- } else if (key === 'globalEnabled') {
- isExtensionEnabled = changes[key].newValue;
- updateState();
- }
+ if ('httpNowhere' in changes) {
+ httpNowhereOn = changes.httpNowhere.newValue;
+ updateState();
+ }
+ if ('showCounter' in changes) {
+ showCounter = changes.showCounter.newValue;
+ updateState();
+ }
+ if ('globalEnabled' in changes) {
+ isExtensionEnabled = changes.globalEnabled.newValue;
+ updateState();
}
}
});
@@ -125,6 +136,25 @@ var loadStoredUserRules = function() {
loadStoredUserRules();
+function getActiveRulesetCount(id) {
+ const applied = activeRulesets.getRulesets(id);
+
+ if (!applied)
+ {
+ return 0;
+ }
+
+ let activeCount = 0;
+
+ for (const key in applied) {
+ if (applied[key].active) {
+ activeCount++;
+ }
+ }
+
+ return activeCount;
+}
+
/**
* Set the icon color correctly
* inactive: extension is enabled, but no rules were triggered on this page.
@@ -136,17 +166,17 @@ var updateState = function() {
if (!chrome.tabs) {
return;
}
- chrome.tabs.query({active: true, currentWindow: true}, function(tabs) {
+ chrome.tabs.query({ active: true, currentWindow: true }, function(tabs) {
if (!tabs || tabs.length === 0) {
return;
}
- var applied = activeRulesets.getRulesets(tabs[0].id)
- var iconState = "inactive";
+ const activeCount = getActiveRulesetCount(tabs[0].id);
+ let iconState = "inactive";
if (!isExtensionEnabled) {
iconState = "disabled";
} else if (httpNowhereOn) {
iconState = "blocking";
- } else if (applied) {
+ } else if (activeCount > 0) {
iconState = "active";
}
chrome.browserAction.setIcon({
@@ -157,6 +187,12 @@ var updateState = function() {
chrome.browserAction.setTitle({
title: "HTTPS Everywhere (" + iconState + ")"
});
+
+ chrome.browserAction.setBadgeBackgroundColor({ color: "#00cc00" });
+
+ const showBadge = activeCount > 0 && isExtensionEnabled && showCounter;
+
+ chrome.browserAction.setBadgeText({ text: showBadge ? String(activeCount) : "" });
});
}
@@ -280,11 +316,11 @@ function onBeforeRequest(details) {
// analysis process
var using_credentials_in_url = false;
if (uri.password || uri.username) {
- using_credentials_in_url = true;
- var tmp_user = uri.username;
- var tmp_pass = uri.password;
- uri.username = null;
- uri.password = null;
+ using_credentials_in_url = true;
+ var tmp_user = uri.username;
+ var tmp_pass = uri.password;
+ uri.username = null;
+ uri.password = null;
}
var canonical_url = uri.href;
@@ -332,10 +368,10 @@ function onBeforeRequest(details) {
// HTTP URIs by parent hostname, along with the resource type.
if (switchPlannerEnabledFor[details.tabId] && uri.protocol !== "https:") {
writeToSwitchPlanner(details.type,
- details.tabId,
- canonical_host,
- details.url,
- newuristr);
+ details.tabId,
+ canonical_host,
+ details.url,
+ newuristr);
}
if (httpNowhereOn) {
@@ -457,28 +493,28 @@ function onCookieChanged(changeInfo) {
if (!changeInfo.removed && !changeInfo.cookie.secure && isExtensionEnabled) {
if (all_rules.shouldSecureCookie(changeInfo.cookie)) {
var cookie = {name:changeInfo.cookie.name,
- value:changeInfo.cookie.value,
- path:changeInfo.cookie.path,
- httpOnly:changeInfo.cookie.httpOnly,
- expirationDate:changeInfo.cookie.expirationDate,
- storeId:changeInfo.cookie.storeId,
- secure: true};
+ value:changeInfo.cookie.value,
+ path:changeInfo.cookie.path,
+ httpOnly:changeInfo.cookie.httpOnly,
+ expirationDate:changeInfo.cookie.expirationDate,
+ storeId:changeInfo.cookie.storeId,
+ secure: true};
// Host-only cookies don't set the domain field.
if (!changeInfo.cookie.hostOnly) {
- cookie.domain = changeInfo.cookie.domain;
+ cookie.domain = changeInfo.cookie.domain;
}
// The cookie API is magical -- we must recreate the URL from the domain and path.
if (changeInfo.cookie.domain[0] == ".") {
- cookie.url = "https://www" + changeInfo.cookie.domain + cookie.path;
+ cookie.url = "https://www" + changeInfo.cookie.domain + cookie.path;
} else {
- cookie.url = "https://" + changeInfo.cookie.domain + cookie.path;
+ cookie.url = "https://" + changeInfo.cookie.domain + cookie.path;
}
// We get repeated events for some cookies because sites change their
// value repeatedly and remove the "secure" flag.
log(DBUG,
- "Securing cookie " + cookie.name + " for " + changeInfo.cookie.domain + ", was secure=" + changeInfo.cookie.secure);
+ "Securing cookie " + cookie.name + " for " + changeInfo.cookie.domain + ", was secure=" + changeInfo.cookie.secure);
chrome.cookies.set(cookie);
}
}
@@ -489,17 +525,17 @@ function onCookieChanged(changeInfo) {
* @param details details for the redirect (see chrome doc)
* */
function onBeforeRedirect(details) {
- // Catch redirect loops (ignoring about:blank, etc. caused by other extensions)
- var prefix = details.redirectUrl.substring(0, 5);
- if (prefix === "http:" || prefix === "https") {
- if (details.requestId in redirectCounter) {
- redirectCounter[details.requestId] += 1;
- log(DBUG, "Got redirect id "+details.requestId+
+ // Catch redirect loops (ignoring about:blank, etc. caused by other extensions)
+ var prefix = details.redirectUrl.substring(0, 5);
+ if (prefix === "http:" || prefix === "https") {
+ if (details.requestId in redirectCounter) {
+ redirectCounter[details.requestId] += 1;
+ log(DBUG, "Got redirect id "+details.requestId+
": "+redirectCounter[details.requestId]);
- } else {
- redirectCounter[details.requestId] = 1;
- }
+ } else {
+ redirectCounter[details.requestId] = 1;
}
+ }
}
// Registers the handler for requests
diff --git a/chromium/devtools-panel.js b/chromium/devtools-panel.js
index 27fc7bef683b..b329fe268c57 100644
--- a/chromium/devtools-panel.js
+++ b/chromium/devtools-panel.js
@@ -8,8 +8,8 @@ function e(id) {
*/
function sendMessage(type) {
chrome.runtime.sendMessage({
- type: type,
- tabId: chrome.devtools.inspectedWindow.tabId,
+ type: type,
+ tabId: chrome.devtools.inspectedWindow.tabId,
});
}
@@ -41,8 +41,8 @@ function disableSwitchPlanner() {
*/
function display() {
chrome.runtime.sendMessage({
- type: "getHosts",
- tabId: chrome.devtools.inspectedWindow.tabId,
+ type: "getHosts",
+ tabId: chrome.devtools.inspectedWindow.tabId,
}, function(response) {
var resources = e("resources");
var switch_planner_details = e("SwitchPlannerDetails");
diff --git a/chromium/devtools.js b/chromium/devtools.js
index 343bee094295..77c69e6e6727 100644
--- a/chromium/devtools.js
+++ b/chromium/devtools.js
@@ -1,6 +1,6 @@
chrome.devtools.panels.create("HTTPS Everywhere",
- "icons/icon-active-38.png",
- "devtools-panel.html",
- function(panel) {
- }
+ "icons/icon-active-38.png",
+ "devtools-panel.html",
+ function(panel) {
+ }
);
diff --git a/chromium/incognito-cache-clearing.js b/chromium/incognito-cache-clearing.js
index c0125a2bb5cf..d00a40213492 100644
--- a/chromium/incognito-cache-clearing.js
+++ b/chromium/incognito-cache-clearing.js
@@ -10,9 +10,9 @@ let incognito_session_exists = false;
* @param window: A standard Window object.
*/
function detect_incognito_creation(window) {
- if (window.incognito === true) {
- incognito_session_exists = true;
- }
+ if (window.incognito === true) {
+ incognito_session_exists = true;
+ }
}
/**
@@ -20,9 +20,9 @@ function detect_incognito_creation(window) {
* Called if an incognito session is destroyed.
*/
function destroy_caches() {
- log(DBUG, "Destroying caches.");
- all_rules.cookieHostCache.clear();
- all_rules.ruleCache.clear();
+ log(DBUG, "Destroying caches.");
+ all_rules.cookieHostCache.clear();
+ all_rules.ruleCache.clear();
}
/**
@@ -30,15 +30,15 @@ function destroy_caches() {
* @param arrayOfWindows: A array of all open Window objects.
*/
function check_for_incognito_session(arrayOfWindows) {
- for (let window of arrayOfWindows) {
- if (window.incognito === true) {
- // An incognito window still exists, so don't destroy caches yet.
- return;
- }
+ for (let window of arrayOfWindows) {
+ if (window.incognito === true) {
+ // An incognito window still exists, so don't destroy caches yet.
+ return;
}
- // All incognito windows have been closed.
- incognito_session_exists = false;
- destroy_caches();
+ }
+ // All incognito windows have been closed.
+ incognito_session_exists = false;
+ destroy_caches();
}
/**
@@ -47,10 +47,10 @@ function check_for_incognito_session(arrayOfWindows) {
* @param windowId: Ignored.
*/
function detect_incognito_destruction(windowId) {
- if (incognito_session_exists) {
- // Are any current windows incognito?
- chrome.windows.getAll(check_for_incognito_session);
- }
+ if (incognito_session_exists) {
+ // Are any current windows incognito?
+ chrome.windows.getAll(check_for_incognito_session);
+ }
}
diff --git a/chromium/options.html b/chromium/options.html
index 3a7ae116aa33..66ee30982e9c 100644
--- a/chromium/options.html
+++ b/chromium/options.html
@@ -1,22 +1,26 @@
-
+
-
-
-
-
+
+
-
+
+
+
+
+
+
+
diff --git a/chromium/options.js b/chromium/options.js
index d979c504e0f2..7c51a6d4d175 100644
--- a/chromium/options.js
+++ b/chromium/options.js
@@ -25,4 +25,13 @@ document.addEventListener("DOMContentLoaded", () => {
});
document.querySelector("form").addEventListener("submit", import_json);
+
+ const showCounter = document.getElementById("showCounter");
+
+ sendMessage("get_option", { showCounter: true }, item => {
+ showCounter.checked = item.showCounter;
+ showCounter.addEventListener("change", event => {
+ sendMessage("set_option", { showCounter: showCounter.checked });
+ });
+ });
});
diff --git a/chromium/popup.js b/chromium/popup.js
index 430b6fc99c15..89dfc86dc011 100644
--- a/chromium/popup.js
+++ b/chromium/popup.js
@@ -192,6 +192,9 @@ document.addEventListener("DOMContentLoaded", function () {
httpNowhereCheckbox.setAttribute('checked', '');
}
});
+
+ e("aboutTitle").setAttribute("title", chrome.i18n.getMessage("about_title"));
+ e("add-rule-link").addEventListener("click", addManualRule);
});
diff --git a/chromium/rules.js b/chromium/rules.js
index 5de01015ba96..ac596f716225 100644
--- a/chromium/rules.js
+++ b/chromium/rules.js
@@ -100,7 +100,7 @@ RuleSet.prototype = {
// Okay, now find the first rule that triggers
for (let rule of this.rules) {
returl = urispec.replace(rule.from_c,
- rule.to);
+ rule.to);
if (returl != urispec) {
return returl;
}
@@ -269,8 +269,8 @@ RuleSets.prototype = {
}
var rule_set = new RuleSet(ruletag.getAttribute("name"),
- default_state,
- note.trim());
+ default_state,
+ note.trim());
// Read user prefs
if (rule_set.name in this.ruleActiveStates) {
@@ -280,7 +280,7 @@ RuleSets.prototype = {
var rules = ruletag.getElementsByTagName("rule");
for (let rule of rules) {
rule_set.rules.push(new Rule(rule.getAttribute("from"),
- rule.getAttribute("to")));
+ rule.getAttribute("to")));
}
var exclusions = ruletag.getElementsByTagName("exclusion");
@@ -304,11 +304,11 @@ RuleSets.prototype = {
var targets = ruletag.getElementsByTagName("target");
for (let target of targets) {
- var host = target.getAttribute("host");
- if (!(host in this.targets)) {
- this.targets[host] = [];
- }
- this.targets[host].push(rule_set);
+ var host = target.getAttribute("host");
+ if (!(host in this.targets)) {
+ this.targets[host] = [];
+ }
+ this.targets[host].push(rule_set);
}
},
@@ -321,8 +321,8 @@ RuleSets.prototype = {
// Have we cached this result? If so, return it!
var cached_item = this.ruleCache.get(host);
if (cached_item !== undefined) {
- log(DBUG, "Ruleset cache hit for " + host + " items:" + cached_item.length);
- return cached_item;
+ log(DBUG, "Ruleset cache hit for " + host + " items:" + cached_item.length);
+ return cached_item;
}
log(DBUG, "Ruleset cache miss for " + host);
@@ -392,7 +392,7 @@ RuleSets.prototype = {
}
if (!this.safeToSecureCookie(hostname)) {
- return null;
+ return null;
}
var potentiallyApplicable = this.potentiallyApplicableRulesets(hostname);
@@ -433,8 +433,8 @@ RuleSets.prototype = {
}
var cached_item = this.cookieHostCache.get(domain);
if (cached_item !== undefined) {
- log(DBUG, "Cookie host cache hit for " + domain);
- return cached_item;
+ log(DBUG, "Cookie host cache hit for " + domain);
+ return cached_item;
}
log(DBUG, "Cookie host cache miss for " + domain);
diff --git a/chromium/translation.js b/chromium/translation.js
index 68eaae85a4e5..d4d65f925b4e 100644
--- a/chromium/translation.js
+++ b/chromium/translation.js
@@ -4,8 +4,4 @@ document.addEventListener("DOMContentLoaded", function () {
for (let el of elem) {
el.innerText = chrome.i18n.getMessage(el.getAttribute("i18n"));
}
-
- // other translations
- e("aboutTitle").setAttribute("title", chrome.i18n.getMessage("about_title"));
- e("add-rule-link").addEventListener("click", addManualRule);
});
diff --git a/chromium/util.js b/chromium/util.js
index 6ecb52b6b2c9..9d926dc1e76e 100644
--- a/chromium/util.js
+++ b/chromium/util.js
@@ -16,12 +16,12 @@ console.log("Type this into the console: DEFAULT_LOG_LEVEL=VERB");
console.log("Accepted levels are VERB, DBUG, INFO, NOTE and WARN, default is NOTE");
function log(level, str) {
- if (level >= DEFAULT_LOG_LEVEL) {
- if (level === WARN) {
- // Show warning with a little yellow icon in Chrome.
- console.warn(str);
- } else {
- console.log(str);
- }
+ if (level >= DEFAULT_LOG_LEVEL) {
+ if (level === WARN) {
+ // Show warning with a little yellow icon in Chrome.
+ console.warn(str);
+ } else {
+ console.log(str);
}
+ }
}
diff --git a/rewriter/rewriter.js b/rewriter/rewriter.js
index 180468c227eb..3fbda2938bdd 100644
--- a/rewriter/rewriter.js
+++ b/rewriter/rewriter.js
@@ -15,14 +15,14 @@
// git diff
var path = require("path"),
- fs = require("fs"),
- DOMParser = require('xmldom').DOMParser,
- readdirp = require('readdirp'),
- es = require('event-stream'),
+ fs = require("fs"),
+ DOMParser = require('xmldom').DOMParser,
+ readdirp = require('readdirp'),
+ es = require('event-stream'),
- rules = require("../chromium/rules"),
+ rules = require("../chromium/rules"),
- URI = require("urijs");
+ URI = require("urijs");
var ruleSets = null;
@@ -35,26 +35,26 @@ function processDir(dir) {
var stream = readdirp({
root: dir,
fileFilter: ['*.html', '*.js', '*.rb', '*.erb', '*.mustache',
- '*.scala', '*.c', '*.cc', '*.cpp', '*.cxx',
- '*.java', '*.go', '*.php', '*.css', '*.pl', '*.py',
- '*.rhtml', '*.sh', '*.yaml']
+ '*.scala', '*.c', '*.cc', '*.cpp', '*.cxx',
+ '*.java', '*.go', '*.php', '*.css', '*.pl', '*.py',
+ '*.rhtml', '*.sh', '*.yaml']
});
stream
- .on('warn', function (err) {
- console.error('non-fatal error', err);
+ .on('warn', function (err) {
+ console.error('non-fatal error', err);
// Optionally call stream.destroy() here in order to abort and cause 'close' to be emitted
- })
- .on('error', function (err) { console.error('fatal error', err); })
- .pipe(es.mapSync(function (entry) {
- var filename = path.join(dir, entry.path);
- console.log("Rewriting " + filename);
- try {
- processFile(filename);
- } catch(e) {
- console.log(filename, e);
- }
- }));
+ })
+ .on('error', function (err) { console.error('fatal error', err); })
+ .pipe(es.mapSync(function (entry) {
+ var filename = path.join(dir, entry.path);
+ console.log("Rewriting " + filename);
+ try {
+ processFile(filename);
+ } catch(e) {
+ console.log(filename, e);
+ }
+ }));
}
/**
diff --git a/src/bootstrap.js b/src/bootstrap.js
index bffa4646d87a..c55cb440ba7d 100644
--- a/src/bootstrap.js
+++ b/src/bootstrap.js
@@ -5,7 +5,7 @@ const CC = Components.classes;
function get_prefs(branch_name){
let o_prefs = CC["@mozilla.org/preferences-service;1"]
- .getService(CI.nsIPrefService);
+ .getService(CI.nsIPrefService);
let o_branch = o_prefs.getBranch(branch_name);
return o_branch;
}
@@ -14,9 +14,9 @@ function get_custom_rulesets_array(){
var loc = "ProfD"; // profile directory
var dir =
CC["@mozilla.org/file/directory_service;1"]
- .getService(CI.nsIProperties)
- .get(loc, CI.nsILocalFile)
- .clone();
+ .getService(CI.nsIProperties)
+ .get(loc, CI.nsILocalFile)
+ .clone();
dir.append("HTTPSEverywhereUserRules");
// Check for existence, if not, create.
if (!dir.exists()) {
@@ -35,9 +35,9 @@ function get_custom_rulesets_array(){
for(let file of files){
var data = "";
var fstream = CC["@mozilla.org/network/file-input-stream;1"]
- .createInstance(CI.nsIFileInputStream);
+ .createInstance(CI.nsIFileInputStream);
var sstream = CC["@mozilla.org/scriptableinputstream;1"]
- .createInstance(CI.nsIScriptableInputStream);
+ .createInstance(CI.nsIScriptableInputStream);
fstream.init(file, -1, 0, 0);
sstream.init(fstream);
diff --git a/src/chrome/content/rules/104.com.tw.xml b/src/chrome/content/rules/104.com.tw.xml
index 0ec1152f43d3..5133450c3139 100644
--- a/src/chrome/content/rules/104.com.tw.xml
+++ b/src/chrome/content/rules/104.com.tw.xml
@@ -1,44 +1,45 @@
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
diff --git a/src/chrome/content/rules/163.com-problematic.xml b/src/chrome/content/rules/163.com-problematic.xml
index 9d23de002dfb..7414b1ab2690 100644
--- a/src/chrome/content/rules/163.com-problematic.xml
+++ b/src/chrome/content/rules/163.com-problematic.xml
@@ -1,16 +1,13 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/163.com.xml b/src/chrome/content/rules/163.com.xml
index f62d8d91e9a8..ddf5322468af 100644
--- a/src/chrome/content/rules/163.com.xml
+++ b/src/chrome/content/rules/163.com.xml
@@ -128,6 +128,8 @@
+
+
diff --git a/src/chrome/content/rules/3g2upl4pq6kufc4m.onion.xml b/src/chrome/content/rules/3g2upl4pq6kufc4m.onion.xml
new file mode 100644
index 000000000000..ad046cc1c13a
--- /dev/null
+++ b/src/chrome/content/rules/3g2upl4pq6kufc4m.onion.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/50gameslike.com.xml b/src/chrome/content/rules/50gameslike.com.xml
new file mode 100644
index 000000000000..80d3ebe20c9e
--- /dev/null
+++ b/src/chrome/content/rules/50gameslike.com.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/6Scan.com.xml b/src/chrome/content/rules/6Scan.com.xml
deleted file mode 100644
index d055c4f04fe6..000000000000
--- a/src/chrome/content/rules/6Scan.com.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/6Scan_Security.com.xml b/src/chrome/content/rules/6Scan_Security.com.xml
new file mode 100644
index 000000000000..f3cd6c21a7c9
--- /dev/null
+++ b/src/chrome/content/rules/6Scan_Security.com.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/AJs_Ski_and_Sports.xml b/src/chrome/content/rules/AJs_Ski_and_Sports.xml
index dbebd3d54c27..eeb1614bde8d 100644
--- a/src/chrome/content/rules/AJs_Ski_and_Sports.xml
+++ b/src/chrome/content/rules/AJs_Ski_and_Sports.xml
@@ -1,21 +1,11 @@
-
-
-
+
-
-
-
-
+
+
-
+
-
\ No newline at end of file
+
diff --git a/src/chrome/content/rules/AMuseWiki.org.xml b/src/chrome/content/rules/AMuseWiki.org.xml
new file mode 100644
index 000000000000..8c5e4bd1b9d0
--- /dev/null
+++ b/src/chrome/content/rules/AMuseWiki.org.xml
@@ -0,0 +1,24 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/AfB-Group.xml b/src/chrome/content/rules/AfB-Group.xml
new file mode 100644
index 000000000000..9ec6b28a1482
--- /dev/null
+++ b/src/chrome/content/rules/AfB-Group.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Amahi.org.xml b/src/chrome/content/rules/Amahi.org.xml
index 1411c3560eeb..3c62463a1d02 100644
--- a/src/chrome/content/rules/Amahi.org.xml
+++ b/src/chrome/content/rules/Amahi.org.xml
@@ -1,78 +1,56 @@
-
-
+
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Aulo.in.xml b/src/chrome/content/rules/Aulo.in.xml
index bdec16b64274..cf84b4ef3ea6 100644
--- a/src/chrome/content/rules/Aulo.in.xml
+++ b/src/chrome/content/rules/Aulo.in.xml
@@ -1,9 +1,20 @@
-
+
+
+
-
+
diff --git a/src/chrome/content/rules/BestOliveOils.com.xml b/src/chrome/content/rules/BestOliveOils.com.xml
new file mode 100644
index 000000000000..b30954e14ecd
--- /dev/null
+++ b/src/chrome/content/rules/BestOliveOils.com.xml
@@ -0,0 +1,19 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Best_Olive_Oils.xml b/src/chrome/content/rules/Best_Olive_Oils.xml
deleted file mode 100644
index 545dddd9479f..000000000000
--- a/src/chrome/content/rules/Best_Olive_Oils.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Bigdinosaur.org.xml b/src/chrome/content/rules/Bigdinosaur.org.xml
index b3c16205e20d..c0a6668d1c36 100644
--- a/src/chrome/content/rules/Bigdinosaur.org.xml
+++ b/src/chrome/content/rules/Bigdinosaur.org.xml
@@ -1,15 +1,26 @@
-
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/BitMitigate.com.xml b/src/chrome/content/rules/BitMitigate.com.xml
new file mode 100644
index 000000000000..d1bcd56b9d48
--- /dev/null
+++ b/src/chrome/content/rules/BitMitigate.com.xml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/BitcoinStore.com.xml b/src/chrome/content/rules/BitcoinStore.com.xml
deleted file mode 100644
index a9e0fbd5be66..000000000000
--- a/src/chrome/content/rules/BitcoinStore.com.xml
+++ /dev/null
@@ -1,21 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/chrome/content/rules/Blockchainbdgpzk.onion.xml b/src/chrome/content/rules/Blockchainbdgpzk.onion.xml
index 0bed62be86c3..918dbfe99e75 100644
--- a/src/chrome/content/rules/Blockchainbdgpzk.onion.xml
+++ b/src/chrome/content/rules/Blockchainbdgpzk.onion.xml
@@ -1,4 +1,4 @@
-
+
diff --git a/src/chrome/content/rules/Bretagne-web.eu.xml b/src/chrome/content/rules/Bretagne-web.eu.xml
deleted file mode 100644
index d4e14d29961a..000000000000
--- a/src/chrome/content/rules/Bretagne-web.eu.xml
+++ /dev/null
@@ -1,31 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Buy-Premium-Tech.xml b/src/chrome/content/rules/Buy-Premium-Tech.xml
deleted file mode 100644
index 41901bd6e0bc..000000000000
--- a/src/chrome/content/rules/Buy-Premium-Tech.xml
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/CJS-CDKeys.com-mixed.xml b/src/chrome/content/rules/CJS-CDKeys.com-mixed.xml
deleted file mode 100644
index d8c093cf06f9..000000000000
--- a/src/chrome/content/rules/CJS-CDKeys.com-mixed.xml
+++ /dev/null
@@ -1,12 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/CJS-CDKeys.com.xml b/src/chrome/content/rules/CJS-CDKeys.com.xml
index cd8e9b0c4b2e..9546cd3b9899 100644
--- a/src/chrome/content/rules/CJS-CDKeys.com.xml
+++ b/src/chrome/content/rules/CJS-CDKeys.com.xml
@@ -1,30 +1,9 @@
-
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
diff --git a/src/chrome/content/rules/CSGO-Skins.com.xml b/src/chrome/content/rules/CSGO-Skins.com.xml
new file mode 100644
index 000000000000..fdbd357e5529
--- /dev/null
+++ b/src/chrome/content/rules/CSGO-Skins.com.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/CSGOItems.pro.xml b/src/chrome/content/rules/CSGOItems.pro.xml
new file mode 100644
index 000000000000..2c1259e45bc1
--- /dev/null
+++ b/src/chrome/content/rules/CSGOItems.pro.xml
@@ -0,0 +1,10 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/CSGOStash.com.xml b/src/chrome/content/rules/CSGOStash.com.xml
new file mode 100644
index 000000000000..e6fb6e67fd25
--- /dev/null
+++ b/src/chrome/content/rules/CSGOStash.com.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/CakeCentral.com.xml b/src/chrome/content/rules/CakeCentral.com.xml
new file mode 100644
index 000000000000..13d68acf6388
--- /dev/null
+++ b/src/chrome/content/rules/CakeCentral.com.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Cake_Central.com.xml b/src/chrome/content/rules/Cake_Central.com.xml
deleted file mode 100644
index ef5a9e1251dc..000000000000
--- a/src/chrome/content/rules/Cake_Central.com.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Calyx-Institute.xml b/src/chrome/content/rules/Calyx-Institute.xml
deleted file mode 100644
index f53ae738042a..000000000000
--- a/src/chrome/content/rules/Calyx-Institute.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/CalyxInstitute.xml b/src/chrome/content/rules/CalyxInstitute.xml
new file mode 100644
index 000000000000..4f54c3e3e356
--- /dev/null
+++ b/src/chrome/content/rules/CalyxInstitute.xml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Cam.ac.uk-falsemixed.xml b/src/chrome/content/rules/Cam.ac.uk-falsemixed.xml
deleted file mode 100644
index cba1418ab221..000000000000
--- a/src/chrome/content/rules/Cam.ac.uk-falsemixed.xml
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Cam.ac.uk-problematic.xml b/src/chrome/content/rules/Cam.ac.uk-problematic.xml
deleted file mode 100644
index e9b7d5f6ad1d..000000000000
--- a/src/chrome/content/rules/Cam.ac.uk-problematic.xml
+++ /dev/null
@@ -1,22 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/CedricVillani.org.xml b/src/chrome/content/rules/CedricVillani.org.xml
new file mode 100644
index 000000000000..d9918d4e32c7
--- /dev/null
+++ b/src/chrome/content/rules/CedricVillani.org.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Color-Of-Change.xml b/src/chrome/content/rules/Color-Of-Change.xml
index 102d5f37caf6..27bf56b51098 100644
--- a/src/chrome/content/rules/Color-Of-Change.xml
+++ b/src/chrome/content/rules/Color-Of-Change.xml
@@ -1,21 +1,10 @@
-
-
-
+
-
-
-
-
https://www.costco.com/ (403)
Other Costco rulesets:
- Costco-static.com.xml
- ^: mismatched, CN: www2.costco.com
-
-
Nonfunctional hosts in *costco.com:
- video *
@@ -37,33 +31,12 @@ Non-2xx HTTP code: http://www.costco.com/ (200) => https://www.costco.com/ (403)
- www.costco.com
-->
-
-
-
-
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
diff --git a/src/chrome/content/rules/CreativeCommons.xml b/src/chrome/content/rules/CreativeCommons.xml
deleted file mode 100644
index 8dcf038c28a9..000000000000
--- a/src/chrome/content/rules/CreativeCommons.xml
+++ /dev/null
@@ -1,44 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Cyphdbyhiddenbhs.onion.xml b/src/chrome/content/rules/Cyphdbyhiddenbhs.onion.xml
index 3dea4d2581d3..3b18d95fa85d 100644
--- a/src/chrome/content/rules/Cyphdbyhiddenbhs.onion.xml
+++ b/src/chrome/content/rules/Cyphdbyhiddenbhs.onion.xml
@@ -3,19 +3,10 @@
For other Cyph coverage, see Cyph.com.xml.
-
- Note: This should be something like platform=tor, to indicate
- that these rules should not go through the fetch tester on the
- non-Tor Internet because they will fail. As an approximation to
- that, we just use platform="mixedcontent", since Tor Browser is a
- mixedcontent platform, and the https-everywhere-checker will skip
- non-default platforms.
-
-
www.cyphdbyhiddenbhs.onion: Mismatched
-->
-
+
diff --git a/src/chrome/content/rules/DGzRS_Die_Seenotretter.xml b/src/chrome/content/rules/DGzRS_Die_Seenotretter.xml
new file mode 100644
index 000000000000..5b1abc650481
--- /dev/null
+++ b/src/chrome/content/rules/DGzRS_Die_Seenotretter.xml
@@ -0,0 +1,32 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/De-Centralize.com.xml b/src/chrome/content/rules/De-Centralize.com.xml
index 00a1016203d4..0b7dbe2fb167 100644
--- a/src/chrome/content/rules/De-Centralize.com.xml
+++ b/src/chrome/content/rules/De-Centralize.com.xml
@@ -1,28 +1,14 @@
-
+
-
-
+
diff --git a/src/chrome/content/rules/Directbox.xml b/src/chrome/content/rules/Directbox.xml
index d2c7164d4387..aa4a16d83f1d 100644
--- a/src/chrome/content/rules/Directbox.xml
+++ b/src/chrome/content/rules/Directbox.xml
@@ -1,24 +1,42 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Discover-Magazine.xml b/src/chrome/content/rules/Discover-Magazine.xml
deleted file mode 100644
index ca051c78c962..000000000000
--- a/src/chrome/content/rules/Discover-Magazine.xml
+++ /dev/null
@@ -1,53 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/DiscoverMagazine.com.xml b/src/chrome/content/rules/DiscoverMagazine.com.xml
new file mode 100644
index 000000000000..cb1532fe60f9
--- /dev/null
+++ b/src/chrome/content/rules/DiscoverMagazine.com.xml
@@ -0,0 +1,22 @@
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/DuckDuckGo.xml b/src/chrome/content/rules/DuckDuckGo.xml
index 962b6bcdbdc1..fd19d25c77b5 100644
--- a/src/chrome/content/rules/DuckDuckGo.xml
+++ b/src/chrome/content/rules/DuckDuckGo.xml
@@ -1,5 +1,6 @@
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Duke-University.xml b/src/chrome/content/rules/Duke-University.xml
deleted file mode 100644
index 1c2b51215965..000000000000
--- a/src/chrome/content/rules/Duke-University.xml
+++ /dev/null
@@ -1,132 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Duke.edu.xml b/src/chrome/content/rules/Duke.edu.xml
new file mode 100644
index 000000000000..e560790321e7
--- /dev/null
+++ b/src/chrome/content/rules/Duke.edu.xml
@@ -0,0 +1,149 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Eltartar_War.xml b/src/chrome/content/rules/Eltartar_War.xml
deleted file mode 100644
index 26a6d8bc5617..000000000000
--- a/src/chrome/content/rules/Eltartar_War.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/chrome/content/rules/FLOSS-Shop.de.xml b/src/chrome/content/rules/FLOSS-Shop.de.xml
new file mode 100644
index 000000000000..f587776330c3
--- /dev/null
+++ b/src/chrome/content/rules/FLOSS-Shop.de.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Freie-Universitat-Berlin.xml b/src/chrome/content/rules/FU-Berlin.de.xml
similarity index 68%
rename from src/chrome/content/rules/Freie-Universitat-Berlin.xml
rename to src/chrome/content/rules/FU-Berlin.de.xml
index 85dc1fb02cab..cac23874cef5 100644
--- a/src/chrome/content/rules/Freie-Universitat-Berlin.xml
+++ b/src/chrome/content/rules/FU-Berlin.de.xml
@@ -1,24 +1,19 @@
-
-
+
+
-
-
-
+
diff --git a/src/chrome/content/rules/FacebookCoreWWWi.onion.xml b/src/chrome/content/rules/FacebookCoreWWWi.onion.xml
index 2e24792b2bbc..9badef5da955 100644
--- a/src/chrome/content/rules/FacebookCoreWWWi.onion.xml
+++ b/src/chrome/content/rules/FacebookCoreWWWi.onion.xml
@@ -4,12 +4,6 @@
For other Facebook coverage, see Facebook.xml.
This ruleset covers Facebook hidden services on Tor.
- Note: This should be something like platform=tor, to indicate
- that these rules should not go through the fetch tester on the
- non-Tor Internet because they will fail. As an approximation to
- that, we just use platform="mixedcontent", since Tor Browser is a
- mixedcontent platform, and the https-everywhere-checker will skip
- non-default platforms.
Fully covered hosts:
@@ -44,7 +38,7 @@
- .facebookcorewwwi.onion
-->
-
+
diff --git a/src/chrome/content/rules/Fail2ban.org.xml b/src/chrome/content/rules/Fail2ban.org.xml
new file mode 100644
index 000000000000..73c64973a6bc
--- /dev/null
+++ b/src/chrome/content/rules/Fail2ban.org.xml
@@ -0,0 +1,7 @@
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/FederalShariatCourt.gov.pk.xml b/src/chrome/content/rules/FederalShariatCourt.gov.pk.xml
new file mode 100644
index 000000000000..433665e35a48
--- /dev/null
+++ b/src/chrome/content/rules/FederalShariatCourt.gov.pk.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Federal_Trade_Commission.xml b/src/chrome/content/rules/Federal_Trade_Commission.xml
index 039dd73c57c0..d437b183b929 100644
--- a/src/chrome/content/rules/Federal_Trade_Commission.xml
+++ b/src/chrome/content/rules/Federal_Trade_Commission.xml
@@ -1,13 +1,5 @@
-
+
-
-
@@ -42,14 +34,11 @@ Fetch error: http://new.ftc.gov/ => https://new.ftc.gov/: (6, 'Could not resolve
-
-
-
-
+
+
diff --git a/src/chrome/content/rules/Financial-Content.xml b/src/chrome/content/rules/Financial-Content.xml
deleted file mode 100644
index a5896cef6476..000000000000
--- a/src/chrome/content/rules/Financial-Content.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/FinancialContent.com.xml b/src/chrome/content/rules/FinancialContent.com.xml
new file mode 100644
index 000000000000..c4c929f39af7
--- /dev/null
+++ b/src/chrome/content/rules/FinancialContent.com.xml
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Flipkart.com.xml b/src/chrome/content/rules/Flipkart.com.xml
index 79e1d55e3c59..d2fea52ce178 100644
--- a/src/chrome/content/rules/Flipkart.com.xml
+++ b/src/chrome/content/rules/Flipkart.com.xml
@@ -6,83 +6,34 @@
Nonfunctional subdomains:
- - blog *
-
- * Refused
-
-
- Problematic subdomains:
-
- - ads *
-
- * Server sends no certificate chain
-
-
- Fully covered subdomains:
-
- - ^
- - seller
-
-
- Insecure cookies are set for these domains and hosts:
-
- - .flipkart.com
- - seller.flipkart.com
-
-
- Mixed content:
-
- - css on seller from fonts.googleapis.com
-
- - Ads/bugs, on:
-
- - www from flipkart-prd.112.2o7.net
- - www from ads.flipkart.com
- - www from b.scorecardresearch.com
-
- - Images on www from img\da.flixcart.com
+ - img[2-9].flipkart.com (m)
+ m: mismatch
-->
-
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
diff --git a/src/chrome/content/rules/FreeUtopia.org.xml b/src/chrome/content/rules/FreeUtopia.org.xml
new file mode 100644
index 000000000000..da63e77a6454
--- /dev/null
+++ b/src/chrome/content/rules/FreeUtopia.org.xml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Free_Utopia.org.xml b/src/chrome/content/rules/Free_Utopia.org.xml
deleted file mode 100644
index 1e372cd84a03..000000000000
--- a/src/chrome/content/rules/Free_Utopia.org.xml
+++ /dev/null
@@ -1,17 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/GeForce.com.xml b/src/chrome/content/rules/GeForce.com.xml
index 42dacffa6669..eb9effb1b885 100644
--- a/src/chrome/content/rules/GeForce.com.xml
+++ b/src/chrome/content/rules/GeForce.com.xml
@@ -1,51 +1,34 @@
-
-
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/GenusDebatten.se.xml b/src/chrome/content/rules/GenusDebatten.se.xml
new file mode 100644
index 000000000000..510cbaef67cf
--- /dev/null
+++ b/src/chrome/content/rules/GenusDebatten.se.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Groupon.com.xml b/src/chrome/content/rules/Groupon.com.xml
index d980fd31d231..e4cff7f980f6 100644
--- a/src/chrome/content/rules/Groupon.com.xml
+++ b/src/chrome/content/rules/Groupon.com.xml
@@ -1,84 +1,32 @@
-
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
+
+
diff --git a/src/chrome/content/rules/Gyazo.com.xml b/src/chrome/content/rules/Gyazo.com.xml
index cdbdad367fc4..8f7ee7e07d66 100644
--- a/src/chrome/content/rules/Gyazo.com.xml
+++ b/src/chrome/content/rules/Gyazo.com.xml
@@ -1,27 +1,29 @@
-
+
+
+
+
+
+
+
-
-
-
-
+
+
-
-
-
+
diff --git a/src/chrome/content/rules/HKGOLDEN.com.xml b/src/chrome/content/rules/HKGOLDEN.com.xml
index 01954b25376e..78e718fae129 100644
--- a/src/chrome/content/rules/HKGOLDEN.com.xml
+++ b/src/chrome/content/rules/HKGOLDEN.com.xml
@@ -1,26 +1,21 @@
-
+
-
diff --git a/src/chrome/content/rules/HealthCheckUSA.com.xml b/src/chrome/content/rules/HealthCheckUSA.com.xml
new file mode 100644
index 000000000000..03075b03c223
--- /dev/null
+++ b/src/chrome/content/rules/HealthCheckUSA.com.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/HealthCheckUSA.xml b/src/chrome/content/rules/HealthCheckUSA.xml
deleted file mode 100644
index 6219aaaf181a..000000000000
--- a/src/chrome/content/rules/HealthCheckUSA.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Hitachi_Data_Systems.xml b/src/chrome/content/rules/Hitachi_Data_Systems.xml
index a6abe4e73679..1bad50cb91cb 100644
--- a/src/chrome/content/rules/Hitachi_Data_Systems.xml
+++ b/src/chrome/content/rules/Hitachi_Data_Systems.xml
@@ -1,20 +1,38 @@
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Human_Rights_Watch.xml b/src/chrome/content/rules/Human_Rights_Watch.xml
index 12469d7a4225..c8bf440819a0 100644
--- a/src/chrome/content/rules/Human_Rights_Watch.xml
+++ b/src/chrome/content/rules/Human_Rights_Watch.xml
@@ -1,66 +1,27 @@
-
-
+
-
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
diff --git a/src/chrome/content/rules/IRIS.edu.xml b/src/chrome/content/rules/IRIS.edu.xml
new file mode 100644
index 000000000000..d0e782addef0
--- /dev/null
+++ b/src/chrome/content/rules/IRIS.edu.xml
@@ -0,0 +1,44 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Incometaxindiaefiling.gov.in.xml b/src/chrome/content/rules/Incometaxindiaefiling.gov.in.xml
new file mode 100644
index 000000000000..d91b9a0846d4
--- /dev/null
+++ b/src/chrome/content/rules/Incometaxindiaefiling.gov.in.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Indymedia.xml b/src/chrome/content/rules/Indymedia.xml
index 6d420e8bd21b..f3644b90567e 100644
--- a/src/chrome/content/rules/Indymedia.xml
+++ b/src/chrome/content/rules/Indymedia.xml
@@ -3,7 +3,6 @@
- Indymedia.nl.xml
- Indymedia.org.uk.xml
- - Northern-Indymedia.org.xml
Nonfunctional hosts in *indymedia.org:
diff --git a/src/chrome/content/rules/KFWebs.net.xml b/src/chrome/content/rules/KFWebs.net.xml
new file mode 100644
index 000000000000..854e95b3eda5
--- /dev/null
+++ b/src/chrome/content/rules/KFWebs.net.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/KF_Webs.net.xml b/src/chrome/content/rules/KF_Webs.net.xml
deleted file mode 100644
index 089e76666dbc..000000000000
--- a/src/chrome/content/rules/KF_Webs.net.xml
+++ /dev/null
@@ -1,40 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Kernel_concepts.xml b/src/chrome/content/rules/Kernel_concepts.xml
deleted file mode 100644
index f3b3ca99ec20..000000000000
--- a/src/chrome/content/rules/Kernel_concepts.xml
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/chrome/content/rules/LUGoNS.org.xml b/src/chrome/content/rules/LUGoNS.org.xml
index dcd194df6649..9dcf44de4bb9 100644
--- a/src/chrome/content/rules/LUGoNS.org.xml
+++ b/src/chrome/content/rules/LUGoNS.org.xml
@@ -1,42 +1,44 @@
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
diff --git a/src/chrome/content/rules/Lithium-clients.xml b/src/chrome/content/rules/Lithium-clients.xml
index f3e08dd56baf..64c08bcec1f1 100644
--- a/src/chrome/content/rules/Lithium-clients.xml
+++ b/src/chrome/content/rules/Lithium-clients.xml
@@ -11,26 +11,15 @@
-->
-
-
-
+
-
-
-
-
-
-
-
+
-
\ No newline at end of file
+
diff --git a/src/chrome/content/rules/Lloydsbank.com.xml b/src/chrome/content/rules/Lloydsbank.com.xml
index 8251c87b4890..8bd2be141a7f 100644
--- a/src/chrome/content/rules/Lloydsbank.com.xml
+++ b/src/chrome/content/rules/Lloydsbank.com.xml
@@ -1,59 +1,14 @@
-
-
-
+
+
@@ -62,42 +17,17 @@ Fetch error: http://secure.lloydsbank.com/ => https://secure.lloydsbank.com/: To
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
-
+
-
+
+
+
diff --git a/src/chrome/content/rules/Locaweb.com.br.xml b/src/chrome/content/rules/Locaweb.com.br.xml
new file mode 100644
index 000000000000..2bc492f52fc9
--- /dev/null
+++ b/src/chrome/content/rules/Locaweb.com.br.xml
@@ -0,0 +1,20 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Locaweb.xml b/src/chrome/content/rules/Locaweb.xml
deleted file mode 100644
index 03c154dc822d..000000000000
--- a/src/chrome/content/rules/Locaweb.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Massengeschmack.tv.xml b/src/chrome/content/rules/Massengeschmack.tv.xml
new file mode 100644
index 000000000000..811d829aeea4
--- /dev/null
+++ b/src/chrome/content/rules/Massengeschmack.tv.xml
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Meetrics.xml b/src/chrome/content/rules/Meetrics.xml
index 738b20cd58e4..fa5439fe0dad 100644
--- a/src/chrome/content/rules/Meetrics.xml
+++ b/src/chrome/content/rules/Meetrics.xml
@@ -1,20 +1,50 @@
-
-
-
+
+
+
-
-
-
+
+
-
+
-
-
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/chrome/content/rules/Mendeley.com.xml b/src/chrome/content/rules/Mendeley.com.xml
new file mode 100644
index 000000000000..c318e7716308
--- /dev/null
+++ b/src/chrome/content/rules/Mendeley.com.xml
@@ -0,0 +1,42 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Mendeley.xml b/src/chrome/content/rules/Mendeley.xml
deleted file mode 100644
index 77f48e51d377..000000000000
--- a/src/chrome/content/rules/Mendeley.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Menshealth.de.xml b/src/chrome/content/rules/Menshealth.de.xml
index f2f8b6f6b993..1b252673566c 100644
--- a/src/chrome/content/rules/Menshealth.de.xml
+++ b/src/chrome/content/rules/Menshealth.de.xml
@@ -1,5 +1,47 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Michal_Hrusecky.xml b/src/chrome/content/rules/Michal_Hrusecky.xml
index edfadf295a6a..6a0c9a95218b 100644
--- a/src/chrome/content/rules/Michal_Hrusecky.xml
+++ b/src/chrome/content/rules/Michal_Hrusecky.xml
@@ -1,23 +1,33 @@
-
-
-
-
-
-
-
-
-
-
+
+
-
\ No newline at end of file
+
+
diff --git a/src/chrome/content/rules/MyFBO.com.xml b/src/chrome/content/rules/MyFBO.com.xml
index df8a9b9ff358..e5205ca39968 100644
--- a/src/chrome/content/rules/MyFBO.com.xml
+++ b/src/chrome/content/rules/MyFBO.com.xml
@@ -1,9 +1,28 @@
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
-
\ No newline at end of file
+
+
diff --git a/src/chrome/content/rules/MyUS.com.xml b/src/chrome/content/rules/MyUS.com.xml
index 5a05f542f377..be7d4d8c851c 100644
--- a/src/chrome/content/rules/MyUS.com.xml
+++ b/src/chrome/content/rules/MyUS.com.xml
@@ -1,64 +1,13 @@
+
-
-
-
-
-
-
-
-
-
-
+
-
-
+
+
diff --git a/src/chrome/content/rules/NIIF.xml b/src/chrome/content/rules/NIIF.xml
index 0874bac9fbd0..c6969e285ff6 100644
--- a/src/chrome/content/rules/NIIF.xml
+++ b/src/chrome/content/rules/NIIF.xml
@@ -1,14 +1,13 @@
-
-
-
+
+
+
+
-
-
+
diff --git a/src/chrome/content/rules/NYTimes.xml b/src/chrome/content/rules/NYTimes.xml
index bc9813ea6ad9..f1357c611834 100644
--- a/src/chrome/content/rules/NYTimes.xml
+++ b/src/chrome/content/rules/NYTimes.xml
@@ -7,6 +7,7 @@
- NYT_Co.me.xml
- NYT_eXaminer.com.xml
- INYT.com.xml
+ - nytimes2tsqtnxek.onion.xml
CDN buckets:
- pimage.timespeople.nytimes.com.amazonaws.com
diff --git a/src/chrome/content/rules/Nic.cz.xml b/src/chrome/content/rules/Nic.cz.xml
index 32418cd95527..346aaeb34fbe 100644
--- a/src/chrome/content/rules/Nic.cz.xml
+++ b/src/chrome/content/rules/Nic.cz.xml
@@ -8,23 +8,13 @@
- MojeID.cz.xml
- Turris.cz.xml
- Observed cookie domains:
- - .
- - .labs *
- - stats ¹
- - www ¹
- ¹ Not secured by server
- * Tracking cookies only
-
- Mixed content:
- - Bugs on knihy from i.creativecommons.org *
- * Secured by us
-
Mismatched:
- jsns.nic.cz
-->
+
+
@@ -35,6 +25,7 @@
+
@@ -43,9 +34,8 @@
-
-
+
diff --git a/src/chrome/content/rules/Northern-Indymedia.org.xml b/src/chrome/content/rules/Northern-Indymedia.org.xml
deleted file mode 100644
index 465aedca5725..000000000000
--- a/src/chrome/content/rules/Northern-Indymedia.org.xml
+++ /dev/null
@@ -1,27 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/OPM.gov.xml b/src/chrome/content/rules/OPM.gov.xml
index fd986d0c3ee1..7b91622fc99b 100644
--- a/src/chrome/content/rules/OPM.gov.xml
+++ b/src/chrome/content/rules/OPM.gov.xml
@@ -1,44 +1,17 @@
+
-
-
-
-
-
-
-
-
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
+
+
-
-
+
diff --git a/src/chrome/content/rules/Ondarossa.info.xml b/src/chrome/content/rules/Ondarossa.info.xml
index 7a60f8d64b0d..7a8126aa5436 100644
--- a/src/chrome/content/rules/Ondarossa.info.xml
+++ b/src/chrome/content/rules/Ondarossa.info.xml
@@ -1,24 +1,31 @@
-
-
+
-
-
+
+
+
+
diff --git a/src/chrome/content/rules/OnlineSBI.com.xml b/src/chrome/content/rules/OnlineSBI.com.xml
index 26bfd61dea92..0a807e7fa2e1 100644
--- a/src/chrome/content/rules/OnlineSBI.com.xml
+++ b/src/chrome/content/rules/OnlineSBI.com.xml
@@ -1,57 +1,19 @@
-
-
-
+
+
+
-
+
@@ -65,24 +27,10 @@ Fetch error: http://cmp.onlinesbi.com/ => https://cmp.onlinesbi.com/: (28, 'Conn
-
-
-
-
-
-
-
-
-
-
-
-
+
-
+
+
diff --git a/src/chrome/content/rules/OpenSUSE.xml b/src/chrome/content/rules/OpenSUSE.xml
index c83e0b712b0e..a5ab2b41d139 100644
--- a/src/chrome/content/rules/OpenSUSE.xml
+++ b/src/chrome/content/rules/OpenSUSE.xml
@@ -1,75 +1,49 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/OpenX.org.xml b/src/chrome/content/rules/OpenX.org.xml
index c9cdf05998d3..46782c0ebece 100644
--- a/src/chrome/content/rules/OpenX.org.xml
+++ b/src/chrome/content/rules/OpenX.org.xml
@@ -1,60 +1,25 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
diff --git a/src/chrome/content/rules/OpenX.xml b/src/chrome/content/rules/OpenX.xml
index 6b744aa26128..454bde8b4081 100644
--- a/src/chrome/content/rules/OpenX.xml
+++ b/src/chrome/content/rules/OpenX.xml
@@ -1,168 +1,77 @@
-
-
-
-
+
+
+
-
-
-
-
+
+
+
+
+
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
diff --git a/src/chrome/content/rules/OsmAnd.net.xml b/src/chrome/content/rules/OsmAnd.net.xml
index 0eb3193bdf28..cdfebe58f0b7 100644
--- a/src/chrome/content/rules/OsmAnd.net.xml
+++ b/src/chrome/content/rules/OsmAnd.net.xml
@@ -1,44 +1,34 @@
-
-
-
-
-
-
-
+
-
+
+
+
+
+
-
+
diff --git a/src/chrome/content/rules/PCPD.org.hk.xml b/src/chrome/content/rules/PCPD.org.hk.xml
new file mode 100644
index 000000000000..efbbf4a3aa3e
--- /dev/null
+++ b/src/chrome/content/rules/PCPD.org.hk.xml
@@ -0,0 +1,19 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/POP.xml b/src/chrome/content/rules/POP.xml
deleted file mode 100644
index abbed0e1ffaa..000000000000
--- a/src/chrome/content/rules/POP.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/PayPal.co.uk.xml b/src/chrome/content/rules/PayPal.co.uk.xml
new file mode 100644
index 000000000000..8bb3838ff11c
--- /dev/null
+++ b/src/chrome/content/rules/PayPal.co.uk.xml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/PayPal.xml b/src/chrome/content/rules/PayPal.xml
index 67a3527b6aad..d7a8746695f1 100644
--- a/src/chrome/content/rules/PayPal.xml
+++ b/src/chrome/content/rules/PayPal.xml
@@ -4,19 +4,14 @@
- PayPal_Forward.xml
- paypalobjects.com.xml
- Where.com.xml
-
+ - PayPal.co.uk.xml
CDN buckets:
- paypal.112.2o7.net
- where-spotlight.s3.amazonaws.com
-
-->
-
-
-
-
@@ -26,18 +21,8 @@
-
-
-
-
-
-
-
-
-
-
+
+
diff --git a/src/chrome/content/rules/Perform.xml b/src/chrome/content/rules/Perform.xml
deleted file mode 100644
index 8a804e53397f..000000000000
--- a/src/chrome/content/rules/Perform.xml
+++ /dev/null
@@ -1,29 +0,0 @@
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/chrome/content/rules/PerformGroup.com.xml b/src/chrome/content/rules/PerformGroup.com.xml
new file mode 100644
index 000000000000..90c4dff6a321
--- /dev/null
+++ b/src/chrome/content/rules/PerformGroup.com.xml
@@ -0,0 +1,19 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Pinimg.com.xml b/src/chrome/content/rules/Pinimg.com.xml
index 3dac26bbb9d6..8ac814412924 100644
--- a/src/chrome/content/rules/Pinimg.com.xml
+++ b/src/chrome/content/rules/Pinimg.com.xml
@@ -1,36 +1,8 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
diff --git a/src/chrome/content/rules/Pinterest.xml b/src/chrome/content/rules/Pinterest.xml
deleted file mode 100644
index 07fd8459897d..000000000000
--- a/src/chrome/content/rules/Pinterest.xml
+++ /dev/null
@@ -1,137 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/PopCash.net.xml b/src/chrome/content/rules/PopCash.net.xml
index d697b77ac200..8112d6a68fe5 100644
--- a/src/chrome/content/rules/PopCash.net.xml
+++ b/src/chrome/content/rules/PopCash.net.xml
@@ -1,16 +1,9 @@
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/PrintFriendly.xml b/src/chrome/content/rules/PrintFriendly.xml
index ff79d9749bd1..5f1ad3fd2912 100644
--- a/src/chrome/content/rules/PrintFriendly.xml
+++ b/src/chrome/content/rules/PrintFriendly.xml
@@ -1,28 +1,28 @@
-
+
-
-
-
-
-
-
+
-
-
-
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Protonirockerxow.onion.xml b/src/chrome/content/rules/Protonirockerxow.onion.xml
index 2fad1ccdac99..2956b3515809 100644
--- a/src/chrome/content/rules/Protonirockerxow.onion.xml
+++ b/src/chrome/content/rules/Protonirockerxow.onion.xml
@@ -8,15 +8,9 @@
- *.protonirockerxow.onion
This ruleset covers ProtonMail hidden services on Tor.
- Note: This should be something like platform=tor, to indicate
- that these rules should not go through the fetch tester on the
- non-Tor Internet because they will fail. As an approximation to
- that, we just use platform="mixedcontent", since Tor Browser is a
- mixedcontent platform, and the https-everywhere-checker will skip
- non-default platforms.
-->
-
+
diff --git a/src/chrome/content/rules/QQ.xml b/src/chrome/content/rules/QQ.xml
index ac2086567ba1..a03e737636d0 100644
--- a/src/chrome/content/rules/QQ.xml
+++ b/src/chrome/content/rules/QQ.xml
@@ -229,6 +229,7 @@
+
diff --git a/src/chrome/content/rules/Qibla.com.xml b/src/chrome/content/rules/Qibla.com.xml
index c4f295885fb3..a085c02004d7 100644
--- a/src/chrome/content/rules/Qibla.com.xml
+++ b/src/chrome/content/rules/Qibla.com.xml
@@ -1,11 +1,9 @@
-
+
+
+
diff --git a/src/chrome/content/rules/RAUR.xml b/src/chrome/content/rules/RAUR.xml
deleted file mode 100644
index 9cc31b521151..000000000000
--- a/src/chrome/content/rules/RAUR.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/RSPB.xml b/src/chrome/content/rules/RSPB.xml
index f0376f73beeb..c0ece1805e54 100644
--- a/src/chrome/content/rules/RSPB.xml
+++ b/src/chrome/content/rules/RSPB.xml
@@ -1,7 +1,10 @@
+
+
-
@@ -10,4 +13,4 @@
-
\ No newline at end of file
+
diff --git a/src/chrome/content/rules/RegardsCitoyens.fr.xml b/src/chrome/content/rules/RegardsCitoyens.fr.xml
new file mode 100644
index 000000000000..978df4edd9d2
--- /dev/null
+++ b/src/chrome/content/rules/RegardsCitoyens.fr.xml
@@ -0,0 +1,27 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Ritter.vg.xml b/src/chrome/content/rules/Ritter.vg.xml
index cad69844caff..949a6793c556 100644
--- a/src/chrome/content/rules/Ritter.vg.xml
+++ b/src/chrome/content/rules/Ritter.vg.xml
@@ -1,11 +1,12 @@
+
-
-
diff --git a/src/chrome/content/rules/SPCA.org.hk.xml b/src/chrome/content/rules/SPCA.org.hk.xml
new file mode 100644
index 000000000000..ea4fd2aef649
--- /dev/null
+++ b/src/chrome/content/rules/SPCA.org.hk.xml
@@ -0,0 +1,27 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/SPL_Center.org.xml b/src/chrome/content/rules/SPL_Center.org.xml
index 183d8b65d527..a6d1e6e830b0 100644
--- a/src/chrome/content/rules/SPL_Center.org.xml
+++ b/src/chrome/content/rules/SPL_Center.org.xml
@@ -1,33 +1,19 @@
-
+ Mismatch:
+ - selma.splcenter.org
-
+-->
+
+
+
-
-
-
-
+
-
-
-
-
+
+
+
+
+
diff --git a/src/chrome/content/rules/Serverloft.com.xml b/src/chrome/content/rules/Serverloft.com.xml
new file mode 100644
index 000000000000..abb9d22d5c61
--- /dev/null
+++ b/src/chrome/content/rules/Serverloft.com.xml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Serverloft.xml b/src/chrome/content/rules/Serverloft.xml
deleted file mode 100644
index 42cc9768b3c3..000000000000
--- a/src/chrome/content/rules/Serverloft.xml
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/SiaHub.info.xml b/src/chrome/content/rules/SiaHub.info.xml
new file mode 100644
index 000000000000..4ed6c1ade1cf
--- /dev/null
+++ b/src/chrome/content/rules/SiaHub.info.xml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Skins.cash.xml b/src/chrome/content/rules/Skins.cash.xml
new file mode 100644
index 000000000000..5a71aea0bc01
--- /dev/null
+++ b/src/chrome/content/rules/Skins.cash.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Smithsonianmag.com.xml b/src/chrome/content/rules/Smithsonianmag.com.xml
index aec55bd810a3..7993445dbb70 100644
--- a/src/chrome/content/rules/Smithsonianmag.com.xml
+++ b/src/chrome/content/rules/Smithsonianmag.com.xml
@@ -1,56 +1,23 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
-
+
+
-
+
diff --git a/src/chrome/content/rules/SnapEngage.com-falsemixed.xml b/src/chrome/content/rules/SnapEngage.com-falsemixed.xml
deleted file mode 100644
index 343baf4ef359..000000000000
--- a/src/chrome/content/rules/SnapEngage.com-falsemixed.xml
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/src/chrome/content/rules/SnapEngage.xml b/src/chrome/content/rules/SnapEngage.xml
index be91c1b6984a..867fe6fea035 100644
--- a/src/chrome/content/rules/SnapEngage.xml
+++ b/src/chrome/content/rules/SnapEngage.xml
@@ -1,82 +1,5 @@
-
-
-
-
-
-
-
-
-
-
-
+ No working URL known:
+ code.snapengage.com
+ Invalid certificate:
+ info.snapengage.com
-
-
-
-
-
-
+-->
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Sony.com.au.xml b/src/chrome/content/rules/Sony.com.au.xml
new file mode 100644
index 000000000000..89ce276c4cce
--- /dev/null
+++ b/src/chrome/content/rules/Sony.com.au.xml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Sony.xml b/src/chrome/content/rules/Sony.xml
index 643ff6f15555..19a6ee1b51ae 100644
--- a/src/chrome/content/rules/Sony.xml
+++ b/src/chrome/content/rules/Sony.xml
@@ -8,6 +8,7 @@
- PlayStation_Network.com.xml
- SCEA.com.xml
- Sony.co.uk.xml
+ - Sony.com.au.xml
- Sony.com.hk.xml
- Sony.com.mx.xml
- Sony.eu.xml
diff --git a/src/chrome/content/rules/SpaceBattles.com.xml b/src/chrome/content/rules/SpaceBattles.com.xml
new file mode 100644
index 000000000000..e3a5e0c41ea9
--- /dev/null
+++ b/src/chrome/content/rules/SpaceBattles.com.xml
@@ -0,0 +1,16 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/SphereUp.xml b/src/chrome/content/rules/SphereUp.xml
new file mode 100644
index 000000000000..88a52f4297bd
--- /dev/null
+++ b/src/chrome/content/rules/SphereUp.xml
@@ -0,0 +1,64 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/src/chrome/content/rules/Spice-space.org.xml b/src/chrome/content/rules/Spice-space.org.xml
index f394a7134d28..74615a202112 100644
--- a/src/chrome/content/rules/Spice-space.org.xml
+++ b/src/chrome/content/rules/Spice-space.org.xml
@@ -1,18 +1,15 @@
-
+
-
-
diff --git a/src/chrome/content/rules/Stallman.org.xml b/src/chrome/content/rules/Stallman.org.xml
index ce60e997d8fc..42357ecc2bb6 100644
--- a/src/chrome/content/rules/Stallman.org.xml
+++ b/src/chrome/content/rules/Stallman.org.xml
@@ -8,6 +8,8 @@
+
+
diff --git a/src/chrome/content/rules/Svbtle.com.xml b/src/chrome/content/rules/Svbtle.com.xml
index 464a23d80067..79404e8c6e23 100644
--- a/src/chrome/content/rules/Svbtle.com.xml
+++ b/src/chrome/content/rules/Svbtle.com.xml
@@ -1,31 +1,25 @@
+
+
+
+
+
+
+
-
-
-
-
+
-
+
diff --git a/src/chrome/content/rules/Swiss-VA.com.xml b/src/chrome/content/rules/Swiss-VA.com.xml
deleted file mode 100644
index 1137d225471b..000000000000
--- a/src/chrome/content/rules/Swiss-VA.com.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/T411.xml b/src/chrome/content/rules/T411.xml
deleted file mode 100644
index 1382b7d41a75..000000000000
--- a/src/chrome/content/rules/T411.xml
+++ /dev/null
@@ -1,67 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/TheAnarchistLibrary.org.xml b/src/chrome/content/rules/TheAnarchistLibrary.org.xml
index c2c84f9ae67e..946c5c1e1b6c 100644
--- a/src/chrome/content/rules/TheAnarchistLibrary.org.xml
+++ b/src/chrome/content/rules/TheAnarchistLibrary.org.xml
@@ -13,7 +13,15 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/TheTrevorProject.org.xml b/src/chrome/content/rules/TheTrevorProject.org.xml
new file mode 100644
index 000000000000..cf405f9a2168
--- /dev/null
+++ b/src/chrome/content/rules/TheTrevorProject.org.xml
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Theory.org.xml b/src/chrome/content/rules/Theory.org.xml
index 367e5766c2e4..074c1044bace 100644
--- a/src/chrome/content/rules/Theory.org.xml
+++ b/src/chrome/content/rules/Theory.org.xml
@@ -1,18 +1,20 @@
-
-
+
+
+
+
+
+
+
+
+
+
+
-
+
diff --git a/src/chrome/content/rules/Third-Door-Media.xml b/src/chrome/content/rules/Third-Door-Media.xml
index 2f78fad17f50..ce7ee111e5db 100644
--- a/src/chrome/content/rules/Third-Door-Media.xml
+++ b/src/chrome/content/rules/Third-Door-Media.xml
@@ -1,33 +1,24 @@
-
-
+
-
-
-
-
-
-
-
+
diff --git a/src/chrome/content/rules/Thumbshots.xml b/src/chrome/content/rules/Thumbshots.xml
index b33a41879e07..1ab762317ada 100644
--- a/src/chrome/content/rules/Thumbshots.xml
+++ b/src/chrome/content/rules/Thumbshots.xml
@@ -1,20 +1,43 @@
-
+
+
-
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
-
+
+
+
+
+
+
-
+
diff --git a/src/chrome/content/rules/Travis_CI.xml b/src/chrome/content/rules/Travis-CI.org.xml
similarity index 50%
rename from src/chrome/content/rules/Travis_CI.xml
rename to src/chrome/content/rules/Travis-CI.org.xml
index 83909c2524e3..37a6e1410450 100644
--- a/src/chrome/content/rules/Travis_CI.xml
+++ b/src/chrome/content/rules/Travis-CI.org.xml
@@ -1,19 +1,19 @@
-
+
@@ -29,19 +29,8 @@
-
-
-
-
-
-
-
-
-
-
+
+
diff --git a/src/chrome/content/rules/Twitter-Counter.xml b/src/chrome/content/rules/Twitter-Counter.xml
index 3b18e070ddf2..af838959d95c 100644
--- a/src/chrome/content/rules/Twitter-Counter.xml
+++ b/src/chrome/content/rules/Twitter-Counter.xml
@@ -1,25 +1,26 @@
-
+
+
+
+
+
+
+
-
-
-
+
diff --git a/src/chrome/content/rules/Ubuntu.xml b/src/chrome/content/rules/Ubuntu.xml
index 2d151e8bc727..e726fa9c4bcc 100644
--- a/src/chrome/content/rules/Ubuntu.xml
+++ b/src/chrome/content/rules/Ubuntu.xml
@@ -72,6 +72,7 @@
+
diff --git a/src/chrome/content/rules/Un4seen.com.xml b/src/chrome/content/rules/Un4seen.com.xml
new file mode 100644
index 000000000000..2829169edb8f
--- /dev/null
+++ b/src/chrome/content/rules/Un4seen.com.xml
@@ -0,0 +1,18 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/University-of-Cambridge.xml b/src/chrome/content/rules/University-of-Cambridge.xml
index 8dbd6b6a1143..1eeb2b2792c2 100644
--- a/src/chrome/content/rules/University-of-Cambridge.xml
+++ b/src/chrome/content/rules/University-of-Cambridge.xml
@@ -1,333 +1,425 @@
-
-
+
+
+
-
-
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
-
-
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
+
+
+
+
+
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
diff --git a/src/chrome/content/rules/University-of-Mary-Washington-blogs.xml b/src/chrome/content/rules/University-of-Mary-Washington-blogs.xml
index 395ebeb6bbdb..840f63dfa0b0 100644
--- a/src/chrome/content/rules/University-of-Mary-Washington-blogs.xml
+++ b/src/chrome/content/rules/University-of-Mary-Washington-blogs.xml
@@ -7,21 +7,15 @@
-
-
+
-
-
-
-
diff --git a/src/chrome/content/rules/University-of-Mary-Washington.xml b/src/chrome/content/rules/University-of-Mary-Washington.xml
index b4d3682292e5..d1b0bfa7078b 100644
--- a/src/chrome/content/rules/University-of-Mary-Washington.xml
+++ b/src/chrome/content/rules/University-of-Mary-Washington.xml
@@ -4,25 +4,46 @@
- University-of-Mary-Washington-blogs.xml
- eagleeye.umw.edu & jamesfarmer.umw.edu are handled in University-of-Mary-Washington-blogs.xml.
-
-
Nonfunctional domains:
- www.library.umw.edu
- (www.)umweagles.com
+ Mixed content:
+ eagleeye.umw.edu
+
-->
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/University_of_Tennessee_Knoxville.xml b/src/chrome/content/rules/University_of_Tennessee_Knoxville.xml
index acf26cc28bdf..c45275ae2ea0 100644
--- a/src/chrome/content/rules/University_of_Tennessee_Knoxville.xml
+++ b/src/chrome/content/rules/University_of_Tennessee_Knoxville.xml
@@ -1,53 +1,41 @@
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Vates.fr.xml b/src/chrome/content/rules/Vates.fr.xml
index d1ef09d0697e..5f3c3713d48f 100644
--- a/src/chrome/content/rules/Vates.fr.xml
+++ b/src/chrome/content/rules/Vates.fr.xml
@@ -1,43 +1,26 @@
-
-
+
-
-
+
-
-
-
-
-
-
+
diff --git a/src/chrome/content/rules/VisualDNA.com.xml b/src/chrome/content/rules/VisualDNA.com.xml
new file mode 100644
index 000000000000..4a169273b3c2
--- /dev/null
+++ b/src/chrome/content/rules/VisualDNA.com.xml
@@ -0,0 +1,34 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Volgistics.com.xml b/src/chrome/content/rules/Volgistics.com.xml
new file mode 100644
index 000000000000..2feff7a140c0
--- /dev/null
+++ b/src/chrome/content/rules/Volgistics.com.xml
@@ -0,0 +1,24 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Volgistics.xml b/src/chrome/content/rules/Volgistics.xml
deleted file mode 100644
index 0ea5d320edcb..000000000000
--- a/src/chrome/content/rules/Volgistics.xml
+++ /dev/null
@@ -1,7 +0,0 @@
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Webstaurant_Store.xml b/src/chrome/content/rules/Webstaurant_Store.xml
index 86637d0b1a46..9ebc5a662d4d 100644
--- a/src/chrome/content/rules/Webstaurant_Store.xml
+++ b/src/chrome/content/rules/Webstaurant_Store.xml
@@ -1,18 +1,20 @@
-
-
+
-
-
+
+
+
+
+
+
+
+
+
+
+
-
+
-
\ No newline at end of file
+
diff --git a/src/chrome/content/rules/Weibo.com-mixedcontent.xml b/src/chrome/content/rules/Weibo.com-mixedcontent.xml
index 3fea4fb7f963..935e82deecaa 100644
--- a/src/chrome/content/rules/Weibo.com-mixedcontent.xml
+++ b/src/chrome/content/rules/Weibo.com-mixedcontent.xml
@@ -6,7 +6,6 @@
-
diff --git a/src/chrome/content/rules/Weibo.com.xml b/src/chrome/content/rules/Weibo.com.xml
index 3fb2c3f1d0c4..caf1d600832e 100644
--- a/src/chrome/content/rules/Weibo.com.xml
+++ b/src/chrome/content/rules/Weibo.com.xml
@@ -10,15 +10,17 @@
sg2.game.weibo.com
yahoo.tw.weibo.com
+ Expired:
+ vdisk.weibo.com
+
MCB:
chart.weibo.com ( Too many redirects )
- e.weibo.com ( https://e.weibo.com/register/register with inline-script http://weibo.com/signup/signup.php )
game.weibo.com
gouwu.weibo.com
s.weibo.com
- widget.weibo.com ( find test in help.sina.com.cn )
Invalid certificate:
+ www.weibo.com ( Mismatched by some strange CDNs. Equal to ^.)
app.weibo.com
book.weibo.com
static.book.weibo.com
@@ -32,13 +34,10 @@
service.weibo.com
vgirl.weibo.com
x.weibo.com
-
- Redirect to http:
- ^
- www.weibo.com
- vdisk.weibo.com
-->
+
+
@@ -48,33 +47,16 @@
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
+
diff --git a/src/chrome/content/rules/Whitepaperdb.de.xml b/src/chrome/content/rules/Whitepaperdb.de.xml
new file mode 100644
index 000000000000..8024aa589fa2
--- /dev/null
+++ b/src/chrome/content/rules/Whitepaperdb.de.xml
@@ -0,0 +1,28 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Y6xjgkgwj47us5ca.onion.xml b/src/chrome/content/rules/Y6xjgkgwj47us5ca.onion.xml
index f6547ecab034..398da03f6224 100644
--- a/src/chrome/content/rules/Y6xjgkgwj47us5ca.onion.xml
+++ b/src/chrome/content/rules/Y6xjgkgwj47us5ca.onion.xml
@@ -3,12 +3,8 @@
For other Intercept coverage, see First_Look.org.xml.
-
- There isn't really any mixed content - it's
- just for fetch testing to be skipped.
-
-->
-
+
diff --git a/src/chrome/content/rules/Zataz.com-falsemixed.xml b/src/chrome/content/rules/Zataz.com-falsemixed.xml
deleted file mode 100644
index 89b645c3a654..000000000000
--- a/src/chrome/content/rules/Zataz.com-falsemixed.xml
+++ /dev/null
@@ -1,13 +0,0 @@
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Zataz.com.xml b/src/chrome/content/rules/Zataz.com.xml
new file mode 100644
index 000000000000..12834e245beb
--- /dev/null
+++ b/src/chrome/content/rules/Zataz.com.xml
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/Zataz.xml b/src/chrome/content/rules/Zataz.xml
deleted file mode 100644
index 986de4b8b5f5..000000000000
--- a/src/chrome/content/rules/Zataz.xml
+++ /dev/null
@@ -1,80 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/Zipcar.xml b/src/chrome/content/rules/Zipcar.xml
index 5e53e33638b4..0d7226abe28f 100644
--- a/src/chrome/content/rules/Zipcar.xml
+++ b/src/chrome/content/rules/Zipcar.xml
@@ -1,9 +1,8 @@
diff --git a/src/chrome/content/rules/adfoc.us-mixedcontent.xml b/src/chrome/content/rules/adfoc.us-mixedcontent.xml
new file mode 100644
index 000000000000..7dc6de9c72f2
--- /dev/null
+++ b/src/chrome/content/rules/adfoc.us-mixedcontent.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/adfoc.us.xml b/src/chrome/content/rules/adfoc.us.xml
new file mode 100644
index 000000000000..6291b9e1311f
--- /dev/null
+++ b/src/chrome/content/rules/adfoc.us.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/ajhackett.com.xml b/src/chrome/content/rules/ajhackett.com.xml
new file mode 100644
index 000000000000..6648a8574549
--- /dev/null
+++ b/src/chrome/content/rules/ajhackett.com.xml
@@ -0,0 +1,24 @@
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/al-sunan.net.xml b/src/chrome/content/rules/al-sunan.net.xml
new file mode 100644
index 000000000000..e43beaef7a8f
--- /dev/null
+++ b/src/chrome/content/rules/al-sunan.net.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/alayam24.com.xml b/src/chrome/content/rules/alayam24.com.xml
new file mode 100644
index 000000000000..b926c3b8fcaa
--- /dev/null
+++ b/src/chrome/content/rules/alayam24.com.xml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/arslan.io.xml b/src/chrome/content/rules/arslan.io.xml
new file mode 100644
index 000000000000..5d89fb9ff716
--- /dev/null
+++ b/src/chrome/content/rules/arslan.io.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/avto.ru.xml b/src/chrome/content/rules/avto.ru.xml
new file mode 100644
index 000000000000..895689d21d75
--- /dev/null
+++ b/src/chrome/content/rules/avto.ru.xml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/bafg.de.xml b/src/chrome/content/rules/bafg.de.xml
new file mode 100644
index 000000000000..4df3e7ac53b3
--- /dev/null
+++ b/src/chrome/content/rules/bafg.de.xml
@@ -0,0 +1,39 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/bafin.de.xml b/src/chrome/content/rules/bafin.de.xml
new file mode 100644
index 000000000000..977970a6e674
--- /dev/null
+++ b/src/chrome/content/rules/bafin.de.xml
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/bicotender.ru.xml b/src/chrome/content/rules/bicotender.ru.xml
new file mode 100644
index 000000000000..b71c483de320
--- /dev/null
+++ b/src/chrome/content/rules/bicotender.ru.xml
@@ -0,0 +1,19 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/cebix.net.xml b/src/chrome/content/rules/cebix.net.xml
new file mode 100644
index 000000000000..31e4d8eaea0b
--- /dev/null
+++ b/src/chrome/content/rules/cebix.net.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/centrify.com.xml b/src/chrome/content/rules/centrify.com.xml
index b965239e08b0..455f6f557e74 100644
--- a/src/chrome/content/rules/centrify.com.xml
+++ b/src/chrome/content/rules/centrify.com.xml
@@ -1,37 +1,16 @@
-
-
+
-
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+ to="https://centrify.statuspage.io/" />
diff --git a/src/chrome/content/rules/cloudonaut.io.xml b/src/chrome/content/rules/cloudonaut.io.xml
new file mode 100644
index 000000000000..dd65fa9459e0
--- /dev/null
+++ b/src/chrome/content/rules/cloudonaut.io.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/creativecommons.net.xml b/src/chrome/content/rules/creativecommons.net.xml
new file mode 100644
index 000000000000..0634e8c4f327
--- /dev/null
+++ b/src/chrome/content/rules/creativecommons.net.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/cscportal.org.uk.xml b/src/chrome/content/rules/cscportal.org.uk.xml
deleted file mode 100644
index 32de35c41ddf..000000000000
--- a/src/chrome/content/rules/cscportal.org.uk.xml
+++ /dev/null
@@ -1,20 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/decentraleyes.org.xml b/src/chrome/content/rules/decentraleyes.org.xml
new file mode 100644
index 000000000000..53cddfca30dd
--- /dev/null
+++ b/src/chrome/content/rules/decentraleyes.org.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/dts-nachrichtenagentur.de.xml b/src/chrome/content/rules/dts-nachrichtenagentur.de.xml
new file mode 100644
index 000000000000..ff1f87d64926
--- /dev/null
+++ b/src/chrome/content/rules/dts-nachrichtenagentur.de.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/elwis.de.xml b/src/chrome/content/rules/elwis.de.xml
new file mode 100644
index 000000000000..8ae0830a0fe9
--- /dev/null
+++ b/src/chrome/content/rules/elwis.de.xml
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/green.ch.xml b/src/chrome/content/rules/green.ch.xml
index fa4bd23c7f0a..bd5a35e14ac4 100644
--- a/src/chrome/content/rules/green.ch.xml
+++ b/src/chrome/content/rules/green.ch.xml
@@ -1,36 +1,41 @@
-
-
+
-
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/https.cat.xml b/src/chrome/content/rules/https.cat.xml
new file mode 100644
index 000000000000..b28e0bedbe24
--- /dev/null
+++ b/src/chrome/content/rules/https.cat.xml
@@ -0,0 +1,11 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/kitaabun.com.xml b/src/chrome/content/rules/kitaabun.com.xml
new file mode 100644
index 000000000000..6d1530ad61d2
--- /dev/null
+++ b/src/chrome/content/rules/kitaabun.com.xml
@@ -0,0 +1,9 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/meb-biz.ru.xml b/src/chrome/content/rules/meb-biz.ru.xml
new file mode 100644
index 000000000000..8c92a602a373
--- /dev/null
+++ b/src/chrome/content/rules/meb-biz.ru.xml
@@ -0,0 +1,16 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/nytimes2tsqtnxek.onion.xml b/src/chrome/content/rules/nytimes2tsqtnxek.onion.xml
new file mode 100644
index 000000000000..850e6228b6b7
--- /dev/null
+++ b/src/chrome/content/rules/nytimes2tsqtnxek.onion.xml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/ogdb.eu.xml b/src/chrome/content/rules/ogdb.eu.xml
new file mode 100644
index 000000000000..d17d5080440d
--- /dev/null
+++ b/src/chrome/content/rules/ogdb.eu.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/opencaching.de.xml b/src/chrome/content/rules/opencaching.de.xml
index 5830b49adaf9..9b414938fe53 100644
--- a/src/chrome/content/rules/opencaching.de.xml
+++ b/src/chrome/content/rules/opencaching.de.xml
@@ -1,19 +1,8 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
\ No newline at end of file
+
diff --git a/src/chrome/content/rules/opencaching.pl.xml b/src/chrome/content/rules/opencaching.pl.xml
index d073eb81a1c9..7d0b68201510 100644
--- a/src/chrome/content/rules/opencaching.pl.xml
+++ b/src/chrome/content/rules/opencaching.pl.xml
@@ -1,19 +1,24 @@
-
-
+
-
-
+
+
diff --git a/src/chrome/content/rules/openx.com-resources.xml b/src/chrome/content/rules/openx.com-resources.xml
deleted file mode 100644
index 9a3423ae53a7..000000000000
--- a/src/chrome/content/rules/openx.com-resources.xml
+++ /dev/null
@@ -1,66 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/chrome/content/rules/rechenkraft.net.xml b/src/chrome/content/rules/rechenkraft.net.xml
new file mode 100644
index 000000000000..543b8d9d67b7
--- /dev/null
+++ b/src/chrome/content/rules/rechenkraft.net.xml
@@ -0,0 +1,16 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/shitcoin.com.xml b/src/chrome/content/rules/shitcoin.com.xml
new file mode 100644
index 000000000000..34be2251f452
--- /dev/null
+++ b/src/chrome/content/rules/shitcoin.com.xml
@@ -0,0 +1,10 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/snta.ru.xml b/src/chrome/content/rules/snta.ru.xml
new file mode 100644
index 000000000000..a9c47ccaee51
--- /dev/null
+++ b/src/chrome/content/rules/snta.ru.xml
@@ -0,0 +1,7 @@
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/sosmedecins-lille.fr.xml b/src/chrome/content/rules/sosmedecins-lille.fr.xml
new file mode 100644
index 000000000000..a75277e5e459
--- /dev/null
+++ b/src/chrome/content/rules/sosmedecins-lille.fr.xml
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/ssi.gouv.fr.xml b/src/chrome/content/rules/ssi.gouv.fr.xml
new file mode 100644
index 000000000000..49cb491603aa
--- /dev/null
+++ b/src/chrome/content/rules/ssi.gouv.fr.xml
@@ -0,0 +1,25 @@
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/stylershop.ru.xml b/src/chrome/content/rules/stylershop.ru.xml
new file mode 100644
index 000000000000..847630a76c23
--- /dev/null
+++ b/src/chrome/content/rules/stylershop.ru.xml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/technik-museum.de.xml b/src/chrome/content/rules/technik-museum.de.xml
new file mode 100644
index 000000000000..bf98ee55336c
--- /dev/null
+++ b/src/chrome/content/rules/technik-museum.de.xml
@@ -0,0 +1,27 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/tomritterbassljd.onion.xml b/src/chrome/content/rules/tomritterbassljd.onion.xml
new file mode 100644
index 000000000000..4352ca0ce50d
--- /dev/null
+++ b/src/chrome/content/rules/tomritterbassljd.onion.xml
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/chrome/content/rules/vdvc.de.xml b/src/chrome/content/rules/vdvc.de.xml
new file mode 100644
index 000000000000..e08938555fea
--- /dev/null
+++ b/src/chrome/content/rules/vdvc.de.xml
@@ -0,0 +1,6 @@
+
+
+
+
+
+
diff --git a/test/rules/coverage.checker.config b/test/rules/coverage.checker.config
index f269915cf93b..9979c664513a 100644
--- a/test/rules/coverage.checker.config
+++ b/test/rules/coverage.checker.config
@@ -4,6 +4,7 @@
[rulesets]
rulesdir = src/chrome/content/rules
check_coverage = true
+check_target_validity = true
check_nonmatch_groups = true
check_test_formatting = true
include_default_off = false
diff --git a/test/rules/requirements.txt b/test/rules/requirements.txt
index 144287114bb8..702314f7fcf3 100644
--- a/test/rules/requirements.txt
+++ b/test/rules/requirements.txt
@@ -2,3 +2,4 @@ pycurl
regex
bsdiff4
python-Levenshtein
+tldextract
diff --git a/test/rules/src/https_everywhere_checker/check_rules.py b/test/rules/src/https_everywhere_checker/check_rules.py
index bf78a22c3382..d2461cfde838 100644
--- a/test/rules/src/https_everywhere_checker/check_rules.py
+++ b/test/rules/src/https_everywhere_checker/check_rules.py
@@ -130,11 +130,18 @@ def fetchUrl(self, plainUrl, transformedUrl, fetcherPlain, fetcherRewriting, rul
logging.debug("Fetching plain page %s", plainUrl)
# If we get an exception (e.g. connection refused,
# connection timeout) on the plain page, don't treat
- # that as a failure.
+ # that as a failure (except DNS resolution errors)
plainRcode, plainPage = None, None
try:
plainRcode, plainPage = fetcherPlain.fetchHtml(plainUrl)
except Exception, e:
+ errno, message = e
+ if errno == 6:
+ message = "Fetch error: %s => %s: %s" % (
+ plainUrl, transformedUrl, e)
+ self.queue_result("error", "fetch-error %s"% e, ruleFname, plainUrl, https_url=transformedUrl)
+ return message
+
logging.debug("Non-fatal fetch error for plain page %s: %s" % (plainUrl, e))
# Compare HTTP return codes - if original page returned 2xx,
@@ -290,6 +297,9 @@ def cli():
checkCoverage = False
if config.has_option("rulesets", "check_coverage"):
checkCoverage = config.getboolean("rulesets", "check_coverage")
+ checkTargetValidity = False
+ if config.has_option("rulesets", "check_target_validity"):
+ checkTargetValidity = config.getboolean("rulesets", "check_target_validity")
checkNonmatchGroups = False
if config.has_option("rulesets", "check_nonmatch_groups"):
checkNonmatchGroups = config.getboolean("rulesets", "check_nonmatch_groups")
@@ -341,6 +351,7 @@ def cli():
rulesets = []
coverageProblemsExist = False
+ targetValidityProblemExist = False
nonmatchGroupProblemsExist = False
testFormattingProblemsExist = False
for xmlFname in xmlFnames:
@@ -363,6 +374,12 @@ def cli():
for problem in problems:
coverageProblemsExist = True
logging.error(problem)
+ if checkTargetValidity:
+ logging.debug("Checking target validity for '%s'." % ruleset.name)
+ problems = ruleset.getTargetValidityProblems()
+ for problem in problems:
+ targetValidityProblemExist = True
+ logging.error(problem)
if checkNonmatchGroups:
logging.debug("Checking non-match groups for '%s'." % ruleset.name)
problems = ruleset.getNonmatchGroupProblems()
@@ -445,6 +462,9 @@ def cli():
if checkCoverage:
if coverageProblemsExist:
return 1 # exit with error code
+ if checkTargetValidity:
+ if targetValidityProblemExist:
+ return 1 # exit with error code
if checkNonmatchGroups:
if nonmatchGroupProblemsExist:
return 1 # exit with error code
diff --git a/test/rules/src/https_everywhere_checker/http_client.py b/test/rules/src/https_everywhere_checker/http_client.py
index a04d35b6270b..422ce749acbf 100644
--- a/test/rules/src/https_everywhere_checker/http_client.py
+++ b/test/rules/src/https_everywhere_checker/http_client.py
@@ -306,6 +306,8 @@ def staticFetch(url, options, platformPath):
buf = cStringIO.StringIO()
headerBuf = cStringIO.StringIO()
+ urlParts = urlparse.urlparse(url)
+
c = pycurl.Curl()
c.setopt(c.URL, url)
c.setopt(c.WRITEFUNCTION, buf.write)
@@ -325,6 +327,8 @@ def staticFetch(url, options, platformPath):
c.setopt(c.SSLVERSION, options.sslVersion)
c.setopt(c.VERBOSE, options.curlVerbose)
c.setopt(c.SSL_CIPHER_LIST, options.cipherList)
+ if urlParts.hostname[-6:] == '.onion':
+ c.setopt(c.PROXY, 'socks5h://127.0.0.1:9050')
c.perform()
bufValue = buf.getvalue()
diff --git a/test/rules/src/https_everywhere_checker/rules.py b/test/rules/src/https_everywhere_checker/rules.py
index 41040b4e74e1..10b4aae4482b 100644
--- a/test/rules/src/https_everywhere_checker/rules.py
+++ b/test/rules/src/https_everywhere_checker/rules.py
@@ -1,6 +1,8 @@
+from tldextract import tldextract
from urlparse import urlparse
import regex
+import socket
class Rule(object):
"""Represents one from->to rule element."""
@@ -179,6 +181,44 @@ def _determineTestApplication(self):
self.determine_test_application_run = True
return self.test_application_problems
+ def getTargetValidityProblems(self):
+ """Verify that each target has a valid TLD in order to prevent problematic rewrite
+ as stated in EFForg/https-everywhere/issues/10877. In particular,
+ right-wildcard target are ignored from this test.
+
+ Returns an array of strings reporting any coverage problems if they exist,
+ or empty list if coverage is sufficient.
+ """
+ problems = self._determineTestApplication()
+ # Next, make sure each target has a valid TLD
+ for target in self.targets:
+ # Ignore right-wildcard targets
+ if target.endswith(".*"):
+ continue
+
+ # Ignore if target is an ipv4 address
+ try:
+ socket.inet_aton(target)
+ continue
+ except:
+ pass
+
+ # Ignore if target is an ipv6 address
+ try:
+ socket.inet_pton(socket.AF_INET6, target)
+ continue
+ except:
+ pass
+
+ # Extract TLD from target if possible
+ res = tldextract.extract(target)
+ if res.suffix == "":
+ problems.append("%s: Target '%s' missing eTLD" % (self.filename, target))
+ elif res.domain == "":
+ problems.append("%s: Target '%s' containing entire eTLD" % (self.filename, target))
+
+ return problems
+
def getCoverageProblems(self):
"""Verify that each rule and each exclusion has the right number of tests
that applies to it. TODO: Also check that each target has the right
diff --git a/test/travis.sh b/test/travis.sh
index c47970f2cc04..83ced9246353 100755
--- a/test/travis.sh
+++ b/test/travis.sh
@@ -77,7 +77,7 @@ if [ "$RULESETS_CHANGED" ]; then
echo >&2 "Testing test URLs in all changed rulesets."
docker_build
# --privileged is required here for miredo to create a network tunnel
- docker run --rm -ti -v $(pwd):/opt -e RULESETS_CHANGED="$RULESETS_CHANGED" --privileged httpse bash -c "service miredo start && test/fetch.sh"
+ docker run --rm -ti -v $(pwd):/opt -e RULESETS_CHANGED="$RULESETS_CHANGED" --privileged httpse bash -c "service miredo start && service tor start && test/fetch.sh"
fi
if [ "$TEST" == "preloaded" ]; then
diff --git a/utils/convert-hsts/index.js b/utils/convert-hsts/index.js
index 42922f649e02..6b374505e290 100644
--- a/utils/convert-hsts/index.js
+++ b/utils/convert-hsts/index.js
@@ -17,59 +17,59 @@ _(push => {
push(null, _.nil);
});
})
-.flatMap(_)
-.pipe(_.pipeline(
- base64.decode(),
- _.split(),
- _.filter(line => !/^\s*\/\//.test(line)),
- JSONStream.parse('entries.*')
-))
-.reduce({
- xml: xmlBuilder.create('rulesetlibrary'),
- rulesets: new Map(),
- greedyInclusions: '(?!)',
- potentialExclusions: new Map()
-}, (acc, { name, mode = '', include_subdomains = false }) => {
- if (mode === 'force-https') {
- const ruleset = acc.xml.ele('ruleset', { name });
- acc.rulesets.set(name, ruleset);
- ruleset.ele('target', {
- host: name
- });
- if (include_subdomains) {
- acc.greedyInclusions += `|${hostToRegex(name)}`;
+ .flatMap(_)
+ .pipe(_.pipeline(
+ base64.decode(),
+ _.split(),
+ _.filter(line => !/^\s*\/\//.test(line)),
+ JSONStream.parse('entries.*')
+ ))
+ .reduce({
+ xml: xmlBuilder.create('rulesetlibrary'),
+ rulesets: new Map(),
+ greedyInclusions: '(?!)',
+ potentialExclusions: new Map()
+ }, (acc, { name, mode = '', include_subdomains = false }) => {
+ if (mode === 'force-https') {
+ const ruleset = acc.xml.ele('ruleset', { name });
+ acc.rulesets.set(name, ruleset);
ruleset.ele('target', {
- host: `*.${name}`
- });
- }
- ruleset.ele('rule', {
- from: '^http:',
- to: 'https:'
- });
- } else {
- acc.potentialExclusions.set(name, include_subdomains);
- }
- return acc;
-})
-.map(acc => {
- const regexp = new RegExp(`\.(${acc.greedyInclusions})$`);
- for (const [ name, include_subdomains ] of acc.potentialExclusions) {
- const match = name.match(regexp);
- if (match) {
- const ruleset = acc.rulesets.get(match[1]);
- ruleset.ele('exclusion', {
- pattern: `^http://${include_subdomains ? '(?:[\\w-]+\\.)*' : ''}${hostToRegex(name)}/`
- });
- ruleset.ele('test', {
- url: `http://${name}/`
+ host: name
});
if (include_subdomains) {
+ acc.greedyInclusions += `|${hostToRegex(name)}`;
+ ruleset.ele('target', {
+ host: `*.${name}`
+ });
+ }
+ ruleset.ele('rule', {
+ from: '^http:',
+ to: 'https:'
+ });
+ } else {
+ acc.potentialExclusions.set(name, include_subdomains);
+ }
+ return acc;
+ })
+ .map(acc => {
+ const regexp = new RegExp(`\.(${acc.greedyInclusions})$`);
+ for (const [ name, include_subdomains ] of acc.potentialExclusions) {
+ const match = name.match(regexp);
+ if (match) {
+ const ruleset = acc.rulesets.get(match[1]);
+ ruleset.ele('exclusion', {
+ pattern: `^http://${include_subdomains ? '(?:[\\w-]+\\.)*' : ''}${hostToRegex(name)}/`
+ });
ruleset.ele('test', {
- url: `http://host-part.${name}/`
+ url: `http://${name}/`
});
+ if (include_subdomains) {
+ ruleset.ele('test', {
+ url: `http://host-part.${name}/`
+ });
+ }
}
}
- }
- return acc.xml.end({ pretty: true });
-})
-.pipe(fs.createWriteStream(`${__dirname}/hsts.xml`));
+ return acc.xml.end({ pretty: true });
+ })
+ .pipe(fs.createWriteStream(`${__dirname}/hsts.xml`));
diff --git a/utils/hsts-prune/index.js b/utils/hsts-prune/index.js
index 661f8c697c94..f5d1b5d9fe5c 100644
--- a/utils/hsts-prune/index.js
+++ b/utils/hsts-prune/index.js
@@ -41,7 +41,7 @@ const firefox_version_fetch = version_url => {
return cb => {
https.get(version_url, res => {
cb(null, res.headers.location
- .match(/firefox-(.*).tar.*/)[1].replace(/\./g, "_"));
+ .match(/firefox-(.*).tar.*/)[1].replace(/\./g, "_"));
});
};
};
@@ -142,7 +142,7 @@ const check_header_directives = (check_domain, cb) => {
max_age = Number(max_age_match[1]);
}
cb(null,
- preload && include_subdomains && max_age >= 10886400);
+ preload && include_subdomains && max_age >= 10886400);
sent_callback = true;
} else {
cb(null, false);
@@ -193,38 +193,38 @@ function remove_target_from_xml(source, target) {
const files =
read_dir(rules_dir)
- .tap(rules => {
- bar = new ProgressBar(':bar', { total: rules.length, stream: process.stdout });
- })
- .sequence()
- .filter(name => {
- if(rulesets_changed){
- return ~rulesets_changed.indexOf(name);
- } else {
- return name.endsWith('.xml');
- }
- });
+ .tap(rules => {
+ bar = new ProgressBar(':bar', { total: rules.length, stream: process.stdout });
+ })
+ .sequence()
+ .filter(name => {
+ if(rulesets_changed){
+ return ~rulesets_changed.indexOf(name);
+ } else {
+ return name.endsWith('.xml');
+ }
+ });
const sources =
files.fork()
- .map(name => read_file(`${rules_dir}/${name}`, 'utf-8'))
- .parallel(10);
+ .map(name => read_file(`${rules_dir}/${name}`, 'utf-8'))
+ .parallel(10);
const rules =
sources.fork()
- .flatMap(parse_xml)
- .errors((err, push) => {
- push(null, { err });
- })
- .zip(files.fork())
- .map(([ { ruleset, err }, name ]) => {
- if (err) {
- err.message += ` (${name})`;
- this.emit('error', err);
- } else {
- return ruleset;
- }
- });
+ .flatMap(parse_xml)
+ .errors((err, push) => {
+ push(null, { err });
+ })
+ .zip(files.fork())
+ .map(([ { ruleset, err }, name ]) => {
+ if (err) {
+ err.message += ` (${name})`;
+ this.emit('error', err);
+ } else {
+ return ruleset;
+ }
+ });
// This async call determines the current versions of the supported browsers
diff --git a/utils/labeller/index.js b/utils/labeller/index.js
index 6d5f9306abd8..99da8f848df6 100644
--- a/utils/labeller/index.js
+++ b/utils/labeller/index.js
@@ -65,7 +65,7 @@ function get_most_recent_pr(alexa, recent_cb){
function github_process_prs(res, pr_cb){
var alexa = res[0],
- most_recent_pr_checked = res[1];
+ most_recent_pr_checked = res[1];
var github = new GitHubApi();
var wildcard_www_regex = /^(www|\*)\.(.+)/
diff --git a/utils/merge-rulesets.js b/utils/merge-rulesets.js
index 7cc96abe2fe2..52b803eefad7 100644
--- a/utils/merge-rulesets.js
+++ b/utils/merge-rulesets.js
@@ -6,11 +6,11 @@
var fs = new ActiveXObject("Scripting.FileSystemObject"),
-shell = new ActiveXObject("WScript.Shell"),
-args = WScript.Arguments,
-scriptFullPath = WScript.ScriptFullName,
-sourceDir = args[0],
-targetFile = args[1];
+ shell = new ActiveXObject("WScript.Shell"),
+ args = WScript.Arguments,
+ scriptFullPath = WScript.ScriptFullName,
+ sourceDir = args[0],
+ targetFile = args[1];
var msg="";
@@ -18,21 +18,21 @@ var msg="";
var enginefile=WScript.FullName;
var stdout=null;
if(enginefile.toLowerCase().indexOf("cscript.exe")>-1){
- stdout=WScript.StdOut;
+ stdout=WScript.StdOut;
}
function getDir(a) {
- return a.substring(0, a.lastIndexOf("\\") || a.lastIndexOf("/"))
+ return a.substring(0, a.lastIndexOf("\\") || a.lastIndexOf("/"))
}
//checking input
var scriptPath = getDir(WScript.ScriptFullName.toString());
if (!sourceDir) {
- sourceDir = sourceDir || (getDir(scriptPath) + "\\src\\chrome\\content\\rules");
+ sourceDir = sourceDir || (getDir(scriptPath) + "\\src\\chrome\\content\\rules");
}
var defaultFileName="default.rulesets";
if (!targetFile) {
- targetFile = sourceDir + "\\" + defaultFileName;
+ targetFile = sourceDir + "\\" + defaultFileName;
}
//shell.Popup(sourceDir, 0, "HTTPS Everywhere Rules Merger",64);
@@ -40,42 +40,42 @@ if (!targetFile) {
if(stdout)
- stdout.WriteLine("Merging rulesets... and removing whitespaces and comments...");
+ stdout.WriteLine("Merging rulesets... and removing whitespaces and comments...");
var infldr = fs.GetFolder(sourceDir);
var res,fileI;
targetFile=fs.CreateTextFile(targetFile);
function clean_up(rulefile){
- //Remove extra whitespace and comments from a rulesets
- rulefile = rulefile.replace(//ig,'');
- rulefile = rulefile.replace(/\s+/ig,' ');
- //rulefile = rulefile.replace(/\s*(to=|from=)/ig," $1");
- rulefile = rulefile.replace(/>\s*, "><");
- //rulefile = rulefile.replace(/<\/ruleset>\s*/ig, " \n");
- rulefile = rulefile.replace(/\s*(\/>|/ig,'');
+ rulefile = rulefile.replace(/\s+/ig,' ');
+ //rulefile = rulefile.replace(/\s*(to=|from=)/ig," $1");
+ rulefile = rulefile.replace(/>\s*, "><");
+ //rulefile = rulefile.replace(/<\/ruleset>\s*/ig, " \n");
+ rulefile = rulefile.replace(/\s*(\/>|');
+ targetFile.Write('');
else
- targetFile.Write('');
+ targetFile.Write('');
var fileNameRx=/\.xml$/i;
for(fileI = new Enumerator(infldr.Files); !fileI.atEnd(); fileI.moveNext()){
- if (file = fileI.item()) {
- var name = file.Name;
- if(!fileNameRx.test(name))continue;
- if(stdout)stdout.WriteLine("Processing file "+name+"...");
- var currentFileStream=file.OpenAsTextStream(1);
- var ruleset = currentFileStream.ReadAll();
- currentFileStream.Close();
- delete currentFileStream;
- ruleset = ruleset.replace("\n");
targetFile.Close();
@@ -84,10 +84,10 @@ delete targetFile;
var currentStageMsg="Merging has been FINISHED!";
if(stdout){
- stdout.WriteLine(currentStageMsg);
+ stdout.WriteLine(currentStageMsg);
}else{
- msg+="\n"+currentStageMsg;
- shell.Popup(msg, 1, "HTTPS Everywhere Rules Merger", 64);
+ msg+="\n"+currentStageMsg;
+ shell.Popup(msg, 1, "HTTPS Everywhere Rules Merger", 64);
}
diff --git a/utils/ruleset-whitelist.csv b/utils/ruleset-whitelist.csv
index f1c36fccb3cb..02de4bde7a63 100644
--- a/utils/ruleset-whitelist.csv
+++ b/utils/ruleset-whitelist.csv
@@ -1,4 +1,6 @@
hash,auto-pass coverage test,auto-pass fetch test,filename
+7404da7bb08bb04c2ce7d138aa2c1672488e99d9af5097c656f7cc2cd2a36cfb,1,0,GOV.UK.xml
+b18aaa63b24e4333450a6523704e29e485506972e8fc4be497e890e79ecef4bf,1,0,PoliceUK.xml
86e2ab8f682d7b1cdc7b8e44fb871ac1241e3d93736d8dc3bb977cb41269028d,1,1,0nl1ne.at.xml
fbb2d56d33f886b53c314eac3446eed8bad7916660ad0709367936fe8335d987,1,1,112_Cafe.com.xml
49120e478094762f6fc73e19a4cde0780b0337ab95a8aa9fc6771608263697b0,1,1,123-reg.xml
@@ -728,6 +730,7 @@ d7baeaa6bec397bdc80535854950e1df5da6e87e37f1d852df3fab12c5764f42,1,1,CoreMotives
2da557485b91db2cd8fd822d4f0c1d8c9d260f035f75827b8721576abb34bf18,1,1,Corporate-ir.net.xml
71251e0392f89cae88afb7ade08bb4679832258a9110d272f04cb4aadd3be46b,1,1,Corporation_Service_Company.xml
96a1e4d8a7a151bf30f2ce5bdbcb762f5322add6297e6a17c1d26ede3953146a,1,1,COSMOS_magazine.xml
+d1698155b22b3b7f5f0ca643cea078451d79ab6779f6f261d8ca54805b3db3e9,0,1,Costco.xml
2468f6840c6141631608ec3bf75e9fb94e1704cfd757a0f331ef2d89376cf59e,1,1,Cotera.xml
14f57a9f712732f4a7d072faea9dd8debb34ac651083459dadd90d2f7b611d3f,1,1,Couchbase.xml
51e4dfd5e80d3187c34dbae64ea978a12df199da807108618c0db357d608742f,1,1,CouncilofAustralianGovernments.xml
@@ -1374,6 +1377,7 @@ d1857ccfe2226d57004bc300c14230b337e7c84e7f38465e80fb6cfb56a8ac5f,1,1,Grnh.se.xml
71f3030e11d49c8922e89dea8d5a86e94e94c45203a8e8017120588f415653bb,1,1,Grocery_Server.com.xml
68b3f815d64c7aea3a15a66b4b7cc6cb3a939652049f0f19acdfcaafd922e8fe,1,1,Grok_Learning.com.xml
d748494d96923aadd849f3a42805350a89e64afb6226bc9e9fac55e6843aa41a,1,1,Grok.org.uk.xml
+9fa1fec5b01de3f893162bb05593529fc9b9f40bdf02f4b00b6ffaf7a0d385dc,0,1,Groupon.com.xml
37102eaee8fe084f69ddb6c5e2c752055312bdbdc57c4a68e12f0d7be7dd2007,1,1,Growery.xml
1167fd0b3a0a006633e2593b352ae55057fdeef558d5dd32a06e3c1b3b1a72af,1,1,Grupo_Avante.org.xml
a06c8510285353ee578bd10abfa9d0972ed9a2fe1f7932226a8a15a9b16a148e,1,1,Gsfacket.se.xml
@@ -3233,7 +3237,6 @@ d3cad14d26c563280c4e79db4b0cf3861e3f31b33ca0eeaa23247d90c54d1599,1,1,The_Informa
ba5cddc5052720f05477eb3d7c182a687f18021b30a937d34458c7d10d5faf8b,1,1,The_Next_Web-problematic.xml
0eaa13eb00dfa89e920c20033aac3643c377713df15945b2afaef3b4fb13d8e4,1,1,The-Next-Web.xml
4a241330c6d4a018f80c27a20703e70c45ecf17cf9fbeda893e47da1e6169937,1,1,The-Open-Group.xml
-4e0af838c4fceca85d9c15610ad185cf241c6229425eb8a45ded944641cc2220,1,1,Theory.org.xml
6ce3ac8cd6caa5c805e60c651cb1b5c5b00eca8e306e9731b6929a39f26e06d5,1,1,The_Patriot_Post.xml
47a59b2dd91d2cfdf21e5a9dc3e4d41cf42a9b52c99dba572e95b1f39c1d3a34,1,1,The-Public-Index.xml
74543ac90a7b3e191da32cd7f530d15156c29648ac63f8d327ea72726dacb6cd,1,1,The-Republic.xml
@@ -3372,7 +3375,6 @@ e1f76e0ccf48b6a764b85cb52644e4f2f569d08b74ea01ff28e0eb4d99111b19,1,1,TV_Tropes.x
e8496bac50ff5ca0aaf25d9a0a49f895c246f8b7d7941ad7e6cf2c8d6439580d,1,1,Tweegy.nl.xml
b35b35365733082ecebdf86f03de9cd93bd738bd52a0239bb07d4507ad792b5d,1,1,Twilight-Laboratories.xml
0b70c89a0d79e5caccad6e3be40dbc99a9c3885b5b59c01c57d775b28546b1bf,1,1,Twinings.xml
-c7c0b0037aa46dbb29cf62af4e7edad4f3745538e64a06b39d41309be61949c4,1,1,Twitter-Counter.xml
7b77852a18ebceedc2978095db85af92d28db9913d71634ba4d68a5f64802c08,1,1,Two_Roads.xml
b6e20e58a85db551dc6b49cef5e67546f73246773c61d31d86c69986ef9a489a,1,1,Tyndall.ie.xml
deae2b1c6be69bae7b6ec4895e585099a2f5374b53776ed4f075d45f4c1cfa6c,1,1,Typepad.xml
diff --git a/utils/trivialize-rules/trivialize-rules.js b/utils/trivialize-rules/trivialize-rules.js
index de289eb27158..2bc2a61e8ad5 100644
--- a/utils/trivialize-rules/trivialize-rules.js
+++ b/utils/trivialize-rules/trivialize-rules.js
@@ -15,158 +15,158 @@ const hostPartRe = VerEx().anyOf(/\w\-/).oneOrMore();
const hostPartWithDotRe = VerEx().find(hostPartRe).then('\\.');
const staticRegExp = VerEx()
- .startOfLine()
- .then('^http://(')
- .beginCapture()
- .multiple(VerEx().find(hostPartWithDotRe).then('|'))
- .then(hostPartWithDotRe)
- .endCapture()
- .then(')')
- .beginCapture()
- .maybe('?')
- .endCapture()
- .beginCapture()
- .multiple(hostPartWithDotRe)
- .then(hostPartRe)
- .endCapture()
- .then('/')
- .endOfLine()
- .stopAtFirst()
- .searchOneLine();
+ .startOfLine()
+ .then('^http://(')
+ .beginCapture()
+ .multiple(VerEx().find(hostPartWithDotRe).then('|'))
+ .then(hostPartWithDotRe)
+ .endCapture()
+ .then(')')
+ .beginCapture()
+ .maybe('?')
+ .endCapture()
+ .beginCapture()
+ .multiple(hostPartWithDotRe)
+ .then(hostPartRe)
+ .endCapture()
+ .then('/')
+ .endOfLine()
+ .stopAtFirst()
+ .searchOneLine();
const tagsRegExps = new Map();
function createTagsRegexp(tag) {
- let re = tagsRegExps.get(tag);
- if (!re) {
- const tagRe = `<${tag}(?:\\s+\\w+=".*?")*\\s*\\/>`;
- re = new RegExp(`(?:${tagRe}\\s*)*${tagRe}`, 'g');
- tagsRegExps.set(tag, re);
- }
- return re;
+ let re = tagsRegExps.get(tag);
+ if (!re) {
+ const tagRe = `<${tag}(?:\\s+\\w+=".*?")*\\s*\\/>`;
+ re = new RegExp(`(?:${tagRe}\\s*)*${tagRe}`, 'g');
+ tagsRegExps.set(tag, re);
+ }
+ return re;
}
function replaceXML(source, tag, newXML) {
- let pos;
- let re = createTagsRegexp(tag);
- source = source.replace(re, (match, index) => {
- if (pos === undefined) {
- pos = index;
- }
- return '';
- });
- if (pos === undefined) {
- throw new Error(`${re}: <${tag} /> was not found in ${source}`);
- }
- return source.slice(0, pos) + newXML + source.slice(pos);
+ let pos;
+ let re = createTagsRegexp(tag);
+ source = source.replace(re, (match, index) => {
+ if (pos === undefined) {
+ pos = index;
+ }
+ return '';
+ });
+ if (pos === undefined) {
+ throw new Error(`${re}: <${tag} /> was not found in ${source}`);
+ }
+ return source.slice(0, pos) + newXML + source.slice(pos);
}
const files =
readDir(rulesDir)
- .tap(rules => {
- bar = new ProgressBar(':bar', { total: rules.length, stream: process.stdout });
- })
- .sequence()
- .filter(name => name.endsWith('.xml'));
+ .tap(rules => {
+ bar = new ProgressBar(':bar', { total: rules.length, stream: process.stdout });
+ })
+ .sequence()
+ .filter(name => name.endsWith('.xml'));
const sources =
files.fork()
- .map(name => readFile(`${rulesDir}/${name}`, 'utf-8'))
- .parallel(10);
+ .map(name => readFile(`${rulesDir}/${name}`, 'utf-8'))
+ .parallel(10);
const rules =
sources.fork()
- .flatMap(parseXML)
- .errors((err, push) => {
- push(null, { err });
- })
- .zip(files.fork())
- .map(([ { ruleset, err }, name ]) => {
- if (err) {
- err.message += ` (${name})`;
- this.emit('error', err);
- } else {
- return ruleset;
- }
- });
+ .flatMap(parseXML)
+ .errors((err, push) => {
+ push(null, { err });
+ })
+ .zip(files.fork())
+ .map(([ { ruleset, err }, name ]) => {
+ if (err) {
+ err.message += ` (${name})`;
+ this.emit('error', err);
+ } else {
+ return ruleset;
+ }
+ });
function isTrivial(rule) {
- return rule.from === '^http:' && rule.to === 'https:';
+ return rule.from === '^http:' && rule.to === 'https:';
}
files.fork().zipAll([ sources.fork(), rules ]).map(([name, source, ruleset]) => {
- bar.tick();
+ bar.tick();
- let target = ruleset.target.map(target => target.$.host);
- let rule = ruleset.rule.map(rule => rule.$);
+ let target = ruleset.target.map(target => target.$.host);
+ let rule = ruleset.rule.map(rule => rule.$);
- if (rule.length === 1 && isTrivial(rule[0])) {
- return;
- }
+ if (rule.length === 1 && isTrivial(rule[0])) {
+ return;
+ }
- let targetRe = new RegExp(`^${target.map(target => `(${target.replace(/\./g, '\\.').replace(/\*/g, '.*')})`).join('|')}$`);
- let domains = [];
+ let targetRe = new RegExp(`^${target.map(target => `(${target.replace(/\./g, '\\.').replace(/\*/g, '.*')})`).join('|')}$`);
+ let domains = [];
- function isStatic(rule) {
- if (isTrivial(rule)) {
- domains = domains.concat(target);
- return true;
- }
+ function isStatic(rule) {
+ if (isTrivial(rule)) {
+ domains = domains.concat(target);
+ return true;
+ }
- const { from, to } = rule;
+ const { from, to } = rule;
- const match = from.match(staticRegExp);
+ const match = from.match(staticRegExp);
- if (!match) {
- // console.error(from);
- return false;
- }
+ if (!match) {
+ // console.error(from);
+ return false;
+ }
- const subDomains = match[1].split('|').map(item => item.slice(0, -2));
- const baseDomain = match[3].replace(/\\(.)/g, '$1');
- const localDomains = subDomains.map(sub => `${sub}.${baseDomain}`);
+ const subDomains = match[1].split('|').map(item => item.slice(0, -2));
+ const baseDomain = match[3].replace(/\\(.)/g, '$1');
+ const localDomains = subDomains.map(sub => `${sub}.${baseDomain}`);
- if (to !== `https://$1${baseDomain}/`) {
- console.error(from, to);
- return false;
- }
+ if (to !== `https://$1${baseDomain}/`) {
+ console.error(from, to);
+ return false;
+ }
- let mismatch = false;
+ let mismatch = false;
- for (const domain of localDomains) {
- if (!targetRe.test(domain)) {
- console.error(target, domain, from);
- mismatch = true;
- }
- }
-
- if (mismatch) {
- return false;
- }
-
- if (match[2] || targetRe.test(baseDomain)) {
- localDomains.unshift(baseDomain);
- }
+ for (const domain of localDomains) {
+ if (!targetRe.test(domain)) {
+ console.error(target, domain, from);
+ mismatch = true;
+ }
+ }
+
+ if (mismatch) {
+ return false;
+ }
+
+ if (match[2] || targetRe.test(baseDomain)) {
+ localDomains.unshift(baseDomain);
+ }
- domains = domains.concat(localDomains);
+ domains = domains.concat(localDomains);
- return true;
- }
+ return true;
+ }
- if (!rule.every(isStatic)) return;
+ if (!rule.every(isStatic)) return;
- domains = Array.from(new Set(domains));
+ domains = Array.from(new Set(domains));
- if (domains.slice().sort().join('\n') !== target.sort().join('\n')) {
- source = replaceXML(source, 'target', domains.map(domain => ` `).join('\n\t'));
- }
+ if (domains.slice().sort().join('\n') !== target.sort().join('\n')) {
+ source = replaceXML(source, 'target', domains.map(domain => ` `).join('\n\t'));
+ }
- source = replaceXML(source, 'rule', ' ');
+ source = replaceXML(source, 'rule', ' ');
- return writeFile(`${rulesDir}/${name}`, source);
+ return writeFile(`${rulesDir}/${name}`, source);
})
-.filter(Boolean)
-.parallel(10)
-.reduce(0, count => count + 1)
-.each(count => console.log(`Rewritten ${count} files.`));
+ .filter(Boolean)
+ .parallel(10)
+ .reduce(0, count => count + 1)
+ .each(count => console.log(`Rewritten ${count} files.`));