mirror of
https://github.com/ytdl-org/youtube-dl.git
synced 2024-11-22 10:11:52 +00:00
Co-authored-by: Julián Romero Parejo <julrompar@alum.us.es>
Co-authored-by: FernandoTC18 <FernandoTC18@users.noreply.github.com> Maintenance and security problems
This commit is contained in:
parent
f0afdbf6ac
commit
481ac5e12c
1 changed files with 2 additions and 2 deletions
|
@ -2360,7 +2360,7 @@ def make_HTTPS_handler(params, **kwargs):
|
||||||
set_alpn_protocols(context)
|
set_alpn_protocols(context)
|
||||||
if opts_no_check_certificate:
|
if opts_no_check_certificate:
|
||||||
context.check_hostname = False
|
context.check_hostname = False
|
||||||
context.verify_mode = ssl.CERT_NONE
|
context.verify_mode = ssl.CERT_REQUIRED
|
||||||
|
|
||||||
try:
|
try:
|
||||||
return YoutubeDLHTTPSHandler(params, context=context, **kwargs)
|
return YoutubeDLHTTPSHandler(params, context=context, **kwargs)
|
||||||
|
@ -2373,7 +2373,7 @@ def make_HTTPS_handler(params, **kwargs):
|
||||||
return YoutubeDLHTTPSHandler(params, **kwargs)
|
return YoutubeDLHTTPSHandler(params, **kwargs)
|
||||||
else: # Python3 < 3.4
|
else: # Python3 < 3.4
|
||||||
context = ssl.SSLContext(ssl.PROTOCOL_TLSv1_2)
|
context = ssl.SSLContext(ssl.PROTOCOL_TLSv1_2)
|
||||||
context.verify_mode = (ssl.CERT_NONE
|
context.verify_mode = (ssl.CERT_REQUIRED
|
||||||
if opts_no_check_certificate
|
if opts_no_check_certificate
|
||||||
else ssl.CERT_REQUIRED)
|
else ssl.CERT_REQUIRED)
|
||||||
context.set_default_verify_paths()
|
context.set_default_verify_paths()
|
||||||
|
|
Loading…
Reference in a new issue