<urlopen error [SSL: CERTIFICATE_VERIFY_FAILED]
See original GitHub issue$ youtube-dl -v -i https://www.youtube.com/watch?v=d7n34bkF-Ew
[debug] System config: []
[debug] User config: ['--proxy', 'http://127.0.0.1:8087', '-o', '~/Downloads/%(title)s.%(ext)s', '-f', '22']
[debug] Command-line args: ['-v', '-i', 'https://www.youtube.com/watch?v=d7n34bkF-Ew']
[debug] Encodings: locale 'UTF-8', fs 'utf-8', out 'UTF-8', pref: 'UTF-8'
[debug] youtube-dl version 2014.03.12
[debug] Python version 3.3.5 - Linux-3.13.7-1-ARCH-x86_64-with-arch
[debug] Proxy map: {'http': 'http://127.0.0.1:8087', 'https': 'http://127.0.0.1:8087'}
[youtube] Setting language
WARNING: unable to set language: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:548)>
[youtube] d7n34bkF-Ew: Downloading webpage
ERROR: Unable to download webpage: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:548)>
File "/usr/lib/python3.3/site-packages/youtube_dl/extractor/common.py", line 192, in _request_webpage
return self._downloader.urlopen(url_or_request)
File "/usr/lib/python3.3/site-packages/youtube_dl/YoutubeDL.py", line 1173, in urlopen
return self._opener.open(req, timeout=self._socket_timeout)
File "/usr/lib/python3.3/urllib/request.py", line 469, in open
response = self._open(req, data)
File "/usr/lib/python3.3/urllib/request.py", line 487, in _open
'_open', req)
File "/usr/lib/python3.3/urllib/request.py", line 447, in _call_chain
result = func(*args)
File "/usr/lib/python3.3/urllib/request.py", line 1289, in https_open
context=self._context, check_hostname=self._check_hostname)
File "/usr/lib/python3.3/urllib/request.py", line 1251, in do_open
raise URLError(err)
I think it’s related to python3, 'cause when I git cloned this repo and ran it with python2, everything just worked.
Issue Analytics
- State:
- Created 9 years ago
- Comments:7 (1 by maintainers)
Top Results From Across the Web
python - urllib and "SSL: CERTIFICATE_VERIFY_FAILED" Error
If you have installed Python 3.6 on OSX and are getting the "SSL: CERTIFICATE_VERIFY_FAILED" error when trying to connect to an https:// site,...
Read more >urllib.error.URLError: <urlopen error [SSL ... - GitHub
URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1129)> #5117.
Read more >[Solved] urllib.error.URLError: [SSL - Clay-Technology World
Simply put, the error seems an error in verifying the SSL certificate. Maybe the target website uses a certificate signed by itself, I'm...
Read more >What is an SSL 'Certificate_Verify_Failed' Error and How Do I ...
SSL certificate_verify_failed errors typically occur as a result of outdated Python default certificates or invalid root certificates. If you're a website owner ...
Read more >How to Fix SSL: CERTIFICATE_VERIFY_FAILED Error In ...
It tracks the certificate chain back to its root for verification. If the certificate is not valid, it will indicate the error. The...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Python 2 does not check certificate validity. You can pass in the
--no-check-certificate
option to skip certificate validation under Python 3 as well. But that’s just handling the symptoms, not the cause of your error.This error indicates that the SSL certificate was incorrect. While it can be caused by misconfiguration, this is a serious issue if you are worried about the privacy or integrity of your video viewing experience.
Does the error occur if you don’t pass in a proxy (i.e. add
--proxy ''
to the command line?) ? What output do get for?
As a reference, you’ll need
--no-check-certificate
anyway as GAE-based proxies, including GoAgent and XX-Net, regenerates all SSL certificates.