[tbb-commits] [tor-launcher/master] Synchronize some prefs.js and get{Bool, Char, Int}Pref() defaults

gk at torproject.org gk at torproject.org
Wed May 23 18:13:51 UTC 2018


commit 51c1dfb76f02f870b60b7b3cdf86cc36b85eec2f
Author: Matthew Finkel <Matthew.Finkel at gmail.com>
Date:   Tue May 15 22:35:09 2018 +0000

    Synchronize some prefs.js and get{Bool,Char,Int}Pref() defaults
---
 src/chrome/content/network-settings.js | 3 ++-
 src/components/tl-process.js           | 3 ++-
 src/components/tl-protocol.js          | 7 ++++---
 3 files changed, 8 insertions(+), 5 deletions(-)

diff --git a/src/chrome/content/network-settings.js b/src/chrome/content/network-settings.js
index dc3c9ab..f86402d 100644
--- a/src/chrome/content/network-settings.js
+++ b/src/chrome/content/network-settings.js
@@ -2533,7 +2533,8 @@ function requestMoatCaptcha(aProxySettings, aMeekClientPath, aMeekClientArgs)
                      aMeekClientPath, aMeekClientArgs)
     .then(()=>
     {
-      let bridgeType = TorLauncherUtil.getCharPref(kPrefBridgeDBType);
+      let bridgeType = TorLauncherUtil.getCharPref(kPrefBridgeDBType,
+                                                   "obfs4");
       moatRequestor.fetchBridges([bridgeType])
       .then(aCaptchaInfo =>
       {
diff --git a/src/components/tl-process.js b/src/components/tl-process.js
index 1c67817..615227f 100644
--- a/src/components/tl-process.js
+++ b/src/components/tl-process.js
@@ -455,7 +455,8 @@ TorProcessService.prototype =
         if (socksPortArg)
         {
           let socksPortFlags = TorLauncherUtil.getCharPref(
-                                  "extensions.torlauncher.socks_port_flags");
+                                  "extensions.torlauncher.socks_port_flags",
+                          "IPv6Traffic PreferIPv6 KeepAliveIsolateSOCKSAuth");
           if (socksPortFlags)
             socksPortArg += ' ' + socksPortFlags;
           args.push("+__SocksPort");
diff --git a/src/components/tl-protocol.js b/src/components/tl-protocol.js
index 6659621..a5fd1d9 100644
--- a/src/components/tl-protocol.js
+++ b/src/components/tl-protocol.js
@@ -53,7 +53,7 @@ function TorProtocolService()
         this.mControlPort = parseInt(env.get("TOR_CONTROL_PORT"), 10);
 
       let useIPC = !isWindows && TorLauncherUtil.getBoolPref(
-                      "extensions.torlauncher.control_port_use_ipc", true);
+                      "extensions.torlauncher.control_port_use_ipc", false);
       if (!this.mControlHost && !this.mControlPort && useIPC)
         this.mControlIPCFile = TorLauncherUtil.getTorFile("control_ipc", false);
       else
@@ -157,7 +157,7 @@ function TorProtocolService()
     if (useIPC === undefined)
     {
       useIPC = !isWindows && TorLauncherUtil.getBoolPref(
-                       "extensions.torlauncher.socks_port_use_ipc", true);
+                       "extensions.torlauncher.socks_port_use_ipc", false);
     }
 
     // Fill in missing SOCKS info from prefs.
@@ -183,6 +183,7 @@ function TorProtocolService()
       {
         let socksPort = TorLauncherUtil.getIntPref("network.proxy.socks_port",
                                                    0);
+        // This pref is set as 0 by default in Firefox, use 9150 if we get 0.
         this.mSOCKSPortInfo.port = (socksPort != 0) ? socksPort : 9150;
       }
     }
@@ -1506,7 +1507,7 @@ TorProtocolService.prototype =
           else
           {
             var maxEntries =
-                    TorLauncherUtil.getIntPref(this.kPrefMaxTorLogEntries, 0);
+                    TorLauncherUtil.getIntPref(this.kPrefMaxTorLogEntries, 1000);
             if ((maxEntries > 0) && (this.mTorLog.length >= maxEntries))
               this.mTorLog.splice(0, 1);
           }





More information about the tbb-commits mailing list