commit fa4e114a20067810af0c5cc6a57aa6e849386418 Author: Georg Koppen gk@torproject.org Date: Tue Sep 6 07:36:04 2016 +0000
fixup! Bug 14272: Make Tor Launcher work with Unix Domain Socket option
Permissions for the Tor data directory are too permissive for control sockets. We adapt them (and those for creating files) to the ones used for Linux bundles by default. This fixes: #20076 and #20075 as FileUtils is not needed anymore (and hence can't be missing in tl-utils.jsm). --- src/components/tl-process.js | 2 -- src/modules/tl-util.jsm | 4 ++-- 2 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/src/components/tl-process.js b/src/components/tl-process.js index c1bbdda..db074b4 100644 --- a/src/components/tl-process.js +++ b/src/components/tl-process.js @@ -16,8 +16,6 @@ XPCOMUtils.defineLazyModuleGetter(this, "TorLauncherUtil", "resource://torlauncher/modules/tl-util.jsm"); XPCOMUtils.defineLazyModuleGetter(this, "TorLauncherLogger", "resource://torlauncher/modules/tl-logger.jsm"); -XPCOMUtils.defineLazyModuleGetter(this, "FileUtils", - "resource://gre/modules/FileUtils.jsm");
function TorProcessService() { diff --git a/src/modules/tl-util.jsm b/src/modules/tl-util.jsm index 528b752..85b5fbe 100644 --- a/src/modules/tl-util.jsm +++ b/src/modules/tl-util.jsm @@ -513,9 +513,9 @@ let TorLauncherUtil = // Public try { if ("tordatadir" == aTorFileType) - f.create(f.DIRECTORY_TYPE, FileUtils.PERMS_DIRECTORY); + f.create(f.DIRECTORY_TYPE, 0700); else - f.create(f.NORMAL_FILE_TYPE, FileUtils.PERMS_FILE); + f.create(f.NORMAL_FILE_TYPE, 0600); } catch (e) {
tbb-commits@lists.torproject.org