[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor-browser/tor-browser-52.1.1esr-7.0-1] Bug 22320: Use pref name 'referer.hideOnionSource' everywhere



commit 326e9aedfec184325ae95059d12e6b674bfa9013
Author: Arthur Edelstein <arthuredelstein@xxxxxxxxx>
Date:   Wed May 24 12:49:27 2017 -0700

    Bug 22320: Use pref name 'referer.hideOnionSource' everywhere
    
    Correcting my mistake in
    https://bugzilla.mozilla.org/show_bug.cgi?id=1305144
---
 modules/libpref/init/all.js             | 2 +-
 netwerk/protocol/http/nsHttpHandler.cpp | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/modules/libpref/init/all.js b/modules/libpref/init/all.js
index 983c93a..b79cc3a 100644
--- a/modules/libpref/init/all.js
+++ b/modules/libpref/init/all.js
@@ -1450,7 +1450,7 @@ pref("network.http.accept.default", "text/html,application/xhtml+xml,application
 pref("network.http.sendRefererHeader",      2);
 // false=real referer, true=spoof referer (use target URI as referer)
 pref("network.http.referer.spoofSource", false);
-// false=allow onion referer, true=hide onion referer (use target URI as referer)
+// false=allow onion referer, true=hide onion referer (use empty referer)
 pref("network.http.referer.hideOnionSource", false);
 // 0=full URI, 1=scheme+host+port+path, 2=scheme+host+port
 pref("network.http.referer.trimmingPolicy", 0);
diff --git a/netwerk/protocol/http/nsHttpHandler.cpp b/netwerk/protocol/http/nsHttpHandler.cpp
index 13c4d3f..4276c71 100644
--- a/netwerk/protocol/http/nsHttpHandler.cpp
+++ b/netwerk/protocol/http/nsHttpHandler.cpp
@@ -1075,8 +1075,8 @@ nsHttpHandler::PrefsChanged(nsIPrefBranch *prefs, const char *pref)
             mSpoofReferrerSource = cVar;
     }
 
-    if (PREF_CHANGED(HTTP_PREF("referer.spoofOnionSource"))) {
-        rv = prefs->GetBoolPref(HTTP_PREF("referer.spoofOnionSource"), &cVar);
+    if (PREF_CHANGED(HTTP_PREF("referer.hideOnionSource"))) {
+        rv = prefs->GetBoolPref(HTTP_PREF("referer.hideOnionSource"), &cVar);
         if (NS_SUCCEEDED(rv))
             mHideOnionReferrerSource = cVar;
     }

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits