Loading sbws/config.default.ini +6 −0 Original line number Diff line number Diff line Loading @@ -21,6 +21,12 @@ data_period = 5 # timeout between bytes received from the server. See # http://docs.python-requests.org/en/master/user/advanced/#timeouts http_timeout = 10 # Timeout in seconds for waiting on a circuit to be built. It MUST be an # **int**. We will use this both as the CircuitBuildTimeout and a timeout # to give to stem for waiting on a circuit to be built since # CircuitBuildTimeout doesn't handle the case of a TLS connection to a relay # taking forever, and probably other not-yet-discovered cases. circuit_timeout = 10 [scanner] # A human-readable string with chars in a-zA-Z0-9 to identify your scanner Loading sbws/globals.py +0 −3 Original line number Diff line number Diff line Loading @@ -20,9 +20,6 @@ TORRC_STARTING_POINT = { 'SocksPort': 'auto', # Easier than password authentication 'CookieAuthentication': '1', # Things needed to make circuits fail a little faster 'LearnCircuitBuildTimeout': '0', 'CircuitBuildTimeout': '10', # To avoid path bias warnings 'UseEntryGuards': '0', } Loading sbws/util/config.py +1 −0 Original line number Diff line number Diff line Loading @@ -126,6 +126,7 @@ def _validate_general(conf): err_tmpl = Template('$sec/$key ($val): $e') ints = { 'data_period': {'minimum': 1, 'maximum': None}, 'circuit_timeout': {'minimum': 1, 'maximum': None}, } floats = { 'http_timeout': {'minimum': 0.0, 'maximum': None}, Loading sbws/util/stem.py +5 −0 Original line number Diff line number Diff line Loading @@ -126,6 +126,11 @@ def launch_tor(conf): 'Log': [ 'NOTICE file {}'.format(section['log']), ], # Things needed to make circuits fail a little faster. We get the # circuit_timeout as a string instead of an int on purpose: stem only # accepts strings. 'LearnCircuitBuildTimeout': '0', 'CircuitBuildTimeout': conf['general']['circuit_timeout'], }) # This block of code reads additional torrc lines from the user's # config.ini so they can add arbitrary additional options. Loading Loading
sbws/config.default.ini +6 −0 Original line number Diff line number Diff line Loading @@ -21,6 +21,12 @@ data_period = 5 # timeout between bytes received from the server. See # http://docs.python-requests.org/en/master/user/advanced/#timeouts http_timeout = 10 # Timeout in seconds for waiting on a circuit to be built. It MUST be an # **int**. We will use this both as the CircuitBuildTimeout and a timeout # to give to stem for waiting on a circuit to be built since # CircuitBuildTimeout doesn't handle the case of a TLS connection to a relay # taking forever, and probably other not-yet-discovered cases. circuit_timeout = 10 [scanner] # A human-readable string with chars in a-zA-Z0-9 to identify your scanner Loading
sbws/globals.py +0 −3 Original line number Diff line number Diff line Loading @@ -20,9 +20,6 @@ TORRC_STARTING_POINT = { 'SocksPort': 'auto', # Easier than password authentication 'CookieAuthentication': '1', # Things needed to make circuits fail a little faster 'LearnCircuitBuildTimeout': '0', 'CircuitBuildTimeout': '10', # To avoid path bias warnings 'UseEntryGuards': '0', } Loading
sbws/util/config.py +1 −0 Original line number Diff line number Diff line Loading @@ -126,6 +126,7 @@ def _validate_general(conf): err_tmpl = Template('$sec/$key ($val): $e') ints = { 'data_period': {'minimum': 1, 'maximum': None}, 'circuit_timeout': {'minimum': 1, 'maximum': None}, } floats = { 'http_timeout': {'minimum': 0.0, 'maximum': None}, Loading
sbws/util/stem.py +5 −0 Original line number Diff line number Diff line Loading @@ -126,6 +126,11 @@ def launch_tor(conf): 'Log': [ 'NOTICE file {}'.format(section['log']), ], # Things needed to make circuits fail a little faster. We get the # circuit_timeout as a string instead of an int on purpose: stem only # accepts strings. 'LearnCircuitBuildTimeout': '0', 'CircuitBuildTimeout': conf['general']['circuit_timeout'], }) # This block of code reads additional torrc lines from the user's # config.ini so they can add arbitrary additional options. Loading