Bug 1200263 - Fixes getReportURL function so Help -> Report Web Forgery works again r=Ratty a=IanN DONTBUILD for comm-esr45 CLOSED TREE THUNDERBIRD452b1_2016051723_RELBRANCH
authorFrank-Rainer Grahl <frgrahl@gmx.net>
Tue, 23 Feb 2016 23:56:34 +0800
branchTHUNDERBIRD452b1_2016051723_RELBRANCH
changeset 27084 390c834aaaa0b80aed625d741cc27b3561ebbe7b
parent 27083 4cc0737d05db7722a58735c1a929dc1c12d9561d
child 27085 0914524726fc235db4c83dcbb4b369ebd6b65a97
push id1850
push userclokep@gmail.com
push dateWed, 08 Mar 2017 19:29:12 +0000
treeherdercomm-esr52@028df196b2d9 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersRatty, IanN
bugs1200263
Bug 1200263 - Fixes getReportURL function so Help -> Report Web Forgery works again r=Ratty a=IanN DONTBUILD for comm-esr45 CLOSED TREE
suite/browser/safeBrowsingOverlay.js
--- a/suite/browser/safeBrowsingOverlay.js
+++ b/suite/browser/safeBrowsingOverlay.js
@@ -20,31 +20,22 @@ var gSafeBrowsing = {
       broadcaster.removeAttribute("disabled");
     else
       broadcaster.setAttribute("disabled", true);
   },
 
   /**
    * Used to report a phishing page or a false positive
    * @param   aName
-   *          A String One of "Phish", "Error", "Malware" or "MalwareError".
+   *          A String One of "Phish", "PhishMistake" or "MalwareMistake".
    * @returns A String containing the report phishing URL.
    */
   getReportURL: function getReportURL(aName) {
-    var reportUrl = SafeBrowsing.getReportURL(aName);
-
     var pageUri = getBrowser().currentURI.cloneIgnoringRef();
-
-    // Remove the query to avoid including potentially sensitive data
-    if (pageUri instanceof Components.interfaces.nsIURL)
-      pageUri.query = "";
-
-    reportUrl += "&url=" + encodeURIComponent(pageUri.asciiSpec);
-
-    return reportUrl;
+    return SafeBrowsing.getReportURL(aName, pageUri);
   },
 
   initOverlay: function initOverlay(aEvent) {
     var popup = document.getElementById("helpPopup");
     popup.addEventListener("popupshowing", gSafeBrowsing.initMenuItems, false);
   }
 }