mirror of
https://github.com/python-telegram-bot/python-telegram-bot.git
synced 2024-11-22 15:17:00 +01:00
urllib3: validate https certificate
This commit is contained in:
parent
b040568b07
commit
574fc8cddf
2 changed files with 3 additions and 1 deletions
|
@ -1,2 +1,3 @@
|
|||
future
|
||||
urllib3
|
||||
certifi
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
|
||||
import json
|
||||
|
||||
import certifi
|
||||
import urllib3
|
||||
|
||||
from telegram import (InputFile, TelegramError)
|
||||
|
@ -33,7 +34,7 @@ def _get_con_pool():
|
|||
return _CON_POOL
|
||||
|
||||
global _CON_POOL
|
||||
_CON_POOL = urllib3.PoolManager(10)
|
||||
_CON_POOL = urllib3.PoolManager(10, cert_reqs='CERT_REQUIRED', ca_certs=certifi.where())
|
||||
return _CON_POOL
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue