Created
June 13, 2017 11:37
-
-
Save sigmapie8/f5179a45aa4adc3fc7a24599c8a5d543 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from stem.process import launch_tor | |
import os | |
def print_lines(line): | |
if("Bootstrapped" in line): | |
print(line) | |
tor_path = os.path.join("<absolute path>\\Tor Browser\\Browser\\TorBrowser\\Tor", "tor.exe") | |
tor = launch_tor(tor_cmd = tor_path, init_msg_handler = print_lines) | |
tor.terminate() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment