feat: 移除SSL验证选项以简化请求配置
This commit is contained in:
parent
d33c37db27
commit
4b3a8ce864
3
main.py
3
main.py
@ -223,8 +223,7 @@ def gettoken(proxy, r=2):
|
|||||||
try:
|
try:
|
||||||
proxy_str = db.get_proxy(proxy)
|
proxy_str = db.get_proxy(proxy)
|
||||||
url = 'https://graphql.api.dailymotion.com/oauth/token'
|
url = 'https://graphql.api.dailymotion.com/oauth/token'
|
||||||
response = requests.post(url, headers=headers, data=data, proxies={"http": proxy_str, "https": proxy_str},
|
response = requests.post(url, headers=headers, data=data, proxies={"http": proxy_str, "https": proxy_str})
|
||||||
verify=False)
|
|
||||||
token = response.json()['access_token']
|
token = response.json()['access_token']
|
||||||
copy_headers = copy.deepcopy(headers1)
|
copy_headers = copy.deepcopy(headers1)
|
||||||
copy_headers['authorization'] = "Bearer " + token
|
copy_headers['authorization'] = "Bearer " + token
|
||||||
|
Loading…
x
Reference in New Issue
Block a user