Python solicita arrojar errores SSL
Este es un seguimiento deSSLError usando solicitudes para python:
Acabo de instalarrequests
en una Mac OSX 10.8.5. Mi primer intento de hacerrequests.get
falló al faltar el certificado:
SSLError: [Errno 1] _ssl.c:504: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed
El hilo de arriba dice buscar/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/requests/cacert.pem
pero en realidad ni siquiera tengo un.../site-packages/requests
directorio. No me queda claro si esto debería haber sido agregado por la instalación (usépip
)
Hilos adicionales y elrequests
documentos dicen instalarcertifi
, Así que lo hice. Pero ahora me sale un error diferente:
python -c 'import requests; requests.get("https://api.github.com/events")' /usr/lib/anaconda/lib/python2.7/site-packages/requests/packages/urllib3/util/ssl_.py:90: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
InsecurePlatformWarning
Traceback (most recent call last):
...
File "/usr/lib/anaconda/lib/python2.7/site-packages/requests/adapters.py", line 431, in send
raise SSLError(e, request=request)
requests.exceptions.SSLError: [Errno 1] _ssl.c:504: error:0D0890A1:asn1 encoding routines:ASN1_verify:unknown message digest algorithm
¡Gracias!