aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Taylor <28744867+user234683@users.noreply.github.com>2020-11-12 12:20:21 -0800
committerGitHub <noreply@github.com>2020-11-12 12:20:21 -0800
commit13fef87f69d8fd6b95d25f24398e9a347abe7229 (patch)
treee0302eeb1975de89879d89c47f0a3fc4de3b520e
parent0589cfb8f76455ac76df91fca89ccf65e8f9beca (diff)
parent770b77ea51fe87b75641193d6e1642b7b682c9b4 (diff)
downloadyt-local-13fef87f69d8fd6b95d25f24398e9a347abe7229.tar.lz
yt-local-13fef87f69d8fd6b95d25f24398e9a347abe7229.tar.xz
yt-local-13fef87f69d8fd6b95d25f24398e9a347abe7229.zip
Merge pull request #38 from user234684/patch-1
use Tor to resolve domain names
-rw-r--r--youtube/util.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/youtube/util.py b/youtube/util.py
index 7bf03db..fe34d0b 100644
--- a/youtube/util.py
+++ b/youtube/util.py
@@ -61,7 +61,7 @@ class TorManager:
def __init__(self):
self.old_tor_connection_pool = None
self.tor_connection_pool = urllib3.contrib.socks.SOCKSProxyManager(
- 'socks5://127.0.0.1:' + str(settings.tor_port) + '/',
+ 'socks5h://127.0.0.1:' + str(settings.tor_port) + '/',
cert_reqs = 'CERT_REQUIRED')
self.tor_pool_refresh_time = time.monotonic()
@@ -76,7 +76,7 @@ class TorManager:
self.old_tor_connection_pool = self.tor_connection_pool
self.tor_connection_pool = urllib3.contrib.socks.SOCKSProxyManager(
- 'socks5://127.0.0.1:' + str(settings.tor_port) + '/',
+ 'socks5h://127.0.0.1:' + str(settings.tor_port) + '/',
cert_reqs = 'CERT_REQUIRED')
self.tor_pool_refresh_time = time.monotonic()