summaryrefslogtreecommitdiff
path: root/base
diff options
context:
space:
mode:
authorGaming4JC <g4jc@hyperbola.info>2019-05-11 21:37:30 -0400
committerGaming4JC <g4jc@hyperbola.info>2019-05-11 21:37:30 -0400
commit0eafaf21dc057de06e49d908888ca8c97459d2ca (patch)
tree640a53f6f197746baa476e9a4e45b35215dad1c3 /base
parent32c56f57df29ca5e57520e94be5d55375c9ca4ee (diff)
downloadiceweasel-uxp-0eafaf21dc057de06e49d908888ca8c97459d2ca.tar.gz
backport UXP - Remove SecurityUI telemetry
Diffstat (limited to 'base')
-rw-r--r--base/content/browser-addons.js13
-rwxr-xr-xbase/content/browser.js39
2 files changed, 0 insertions, 52 deletions
diff --git a/base/content/browser-addons.js b/base/content/browser-addons.js
index 1d88153..733114b 100644
--- a/base/content/browser-addons.js
+++ b/base/content/browser-addons.js
@@ -145,10 +145,6 @@ const gXPInstallObserver = {
for (let install of installInfo.installs)
install.install();
installInfo = null;
-
- Services.telemetry
- .getHistogramById("SECURITY_UI")
- .add(Ci.nsISecurityUITelemetry.WARNING_CONFIRM_ADDON_INSTALL_CLICK_THROUGH);
};
break;
}
@@ -208,10 +204,6 @@ const gXPInstallObserver = {
options);
removeNotificationOnEnd(popup, installInfo.installs);
-
- Services.telemetry
- .getHistogramById("SECURITY_UI")
- .add(Ci.nsISecurityUITelemetry.WARNING_CONFIRM_ADDON_INSTALL);
},
observe: function (aSubject, aTopic, aData)
@@ -262,8 +254,6 @@ const gXPInstallObserver = {
messageString = gNavigatorBundle.getFormattedString("xpinstallPromptMessage",
[brandShortName]);
- let secHistogram = Components.classes["@mozilla.org/base/telemetry;1"].getService(Ci.nsITelemetry).getHistogramById("SECURITY_UI");
- secHistogram.add(Ci.nsISecurityUITelemetry.WARNING_ADDON_ASKING_PREVENTED);
let popup = PopupNotifications.show(browser, notificationID,
messageString, anchorID,
null, null, options);
@@ -273,17 +263,14 @@ const gXPInstallObserver = {
messageString = gNavigatorBundle.getFormattedString("xpinstallPromptMessage",
[brandShortName]);
- let secHistogram = Components.classes["@mozilla.org/base/telemetry;1"].getService(Ci.nsITelemetry).getHistogramById("SECURITY_UI");
action = {
label: gNavigatorBundle.getString("xpinstallPromptAllowButton"),
accessKey: gNavigatorBundle.getString("xpinstallPromptAllowButton.accesskey"),
callback: function() {
- secHistogram.add(Ci.nsISecurityUITelemetry.WARNING_ADDON_ASKING_PREVENTED_CLICK_THROUGH);
installInfo.install();
}
};
- secHistogram.add(Ci.nsISecurityUITelemetry.WARNING_ADDON_ASKING_PREVENTED);
let popup = PopupNotifications.show(browser, notificationID,
messageString, anchorID,
action, null, options);
diff --git a/base/content/browser.js b/base/content/browser.js
index 7d301a7..fb52a14 100755
--- a/base/content/browser.js
+++ b/base/content/browser.js
@@ -2768,15 +2768,10 @@ var BrowserOnClick = {
},
onCertError: function (browser, elementId, isTopFrame, location, securityInfoAsString) {
- let secHistogram = Services.telemetry.getHistogramById("SECURITY_UI");
let securityInfo;
switch (elementId) {
case "exceptionDialogButton":
- if (isTopFrame) {
- secHistogram.add(Ci.nsISecurityUITelemetry.WARNING_BAD_CERT_TOP_CLICK_ADD_EXCEPTION);
- }
-
securityInfo = getSecurityInfo(securityInfoAsString);
let sslStatus = securityInfo.QueryInterface(Ci.nsISSLStatusProvider)
.SSLStatus;
@@ -2804,17 +2799,10 @@ var BrowserOnClick = {
break;
case "returnButton":
- if (isTopFrame) {
- secHistogram.add(Ci.nsISecurityUITelemetry.WARNING_BAD_CERT_TOP_GET_ME_OUT_OF_HERE);
- }
goBackFromErrorPage();
break;
case "advancedButton":
- if (isTopFrame) {
- secHistogram.add(Ci.nsISecurityUITelemetry.WARNING_BAD_CERT_TOP_UNDERSTAND_RISKS);
- }
-
securityInfo = getSecurityInfo(securityInfoAsString);
let errorInfo = getDetailedCertErrorInfo(location,
securityInfo);
@@ -2839,46 +2827,19 @@ var BrowserOnClick = {
onAboutBlocked: function (elementId, reason, isTopFrame, location) {
// Depending on what page we are displaying here (malware/phishing/unwanted)
// use the right strings and links for each.
- let bucketName = "";
- let sendTelemetry = false;
- if (reason === 'malware') {
- sendTelemetry = true;
- bucketName = "WARNING_MALWARE_PAGE_";
- } else if (reason === 'phishing') {
- sendTelemetry = true;
- bucketName = "WARNING_PHISHING_PAGE_";
- } else if (reason === 'unwanted') {
- sendTelemetry = true;
- bucketName = "WARNING_UNWANTED_PAGE_";
- }
- let secHistogram = Services.telemetry.getHistogramById("SECURITY_UI");
- let nsISecTel = Ci.nsISecurityUITelemetry;
- bucketName += isTopFrame ? "TOP_" : "FRAME_";
switch (elementId) {
case "getMeOutButton":
- if (sendTelemetry) {
- secHistogram.add(nsISecTel[bucketName + "GET_ME_OUT_OF_HERE"]);
- }
getMeOutOfHere();
break;
case "reportButton":
// This is the "Why is this site blocked" button. We redirect
// to the generic page describing phishing/malware protection.
-
- // We log even if malware/phishing/unwanted info URL couldn't be found:
- // the measurement is for how many users clicked the WHY BLOCKED button
- if (sendTelemetry) {
- secHistogram.add(nsISecTel[bucketName + "WHY_BLOCKED"]);
- }
openHelpLink("phishing-malware", false, "current");
break;
case "ignoreWarningButton":
if (gPrefService.getBoolPref("browser.safebrowsing.allowOverride")) {
- if (sendTelemetry) {
- secHistogram.add(nsISecTel[bucketName + "IGNORE_WARNING"]);
- }
this.ignoreWarningButton(reason);
}
break;