fix tor dir being too open

master
Kevin Froman 2020-02-02 03:23:59 -06:00
parent 8e5152a14e
commit 8a82e76182
4 changed files with 7 additions and 3 deletions

View File

@ -13,6 +13,7 @@ import platform # For windows sigkill workaround
from onionrtypes import BooleanSuccessState from onionrtypes import BooleanSuccessState
import logger import logger
import filepaths
from .. import getopenport from .. import getopenport
from .. import watchdog from .. import watchdog
from . import customtorrc from . import customtorrc

View File

@ -114,6 +114,10 @@ def daemon():
if not offline_mode: if not offline_mode:
if use_existing_tor: if use_existing_tor:
try:
os.mkdir(filepaths.tor_hs_loc)
except FileExistsError:
pass
net.socksPort = config.get('tor.existing_socks_port') net.socksPort = config.get('tor.existing_socks_port')
try: try:
net.myID = create_onion_service( net.myID = create_onion_service(

View File

@ -28,8 +28,7 @@ def create_dirs():
order of the hardcoded list below, order of the hardcoded list below,
then trigger creation of DBs""" then trigger creation of DBs"""
gen_dirs = [home, filepaths.block_data_location, gen_dirs = [home, filepaths.block_data_location,
filepaths.contacts_location, filepaths.export_location, filepaths.contacts_location, filepaths.export_location]
filepaths.tor_hs_loc]
for path in gen_dirs: for path in gen_dirs:
if not os.path.exists(path): if not os.path.exists(path):
os.mkdir(path) os.mkdir(path)

View File

@ -1 +1 @@
1580633234 1580635315