python - SSL Error when using local cert to verify -
error message data
traceback (most recent call last): file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\urllib3\util\ssl_.py", line 313, in ssl_wrap_socket context.load_verify_locations(ca_certs, ca_cert_dir) ssl.sslerror: unknown error (_ssl.c:3510) during handling of above exception, exception occurred: traceback (most recent call last): file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\urllib3\connectionpool.py", line 601, in urlopen chunked=chunked) file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\urllib3\connectionpool.py", line 346, in _make_request self._validate_conn(conn) file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\urllib3\connectionpool.py", line 850, in _validate_conn conn.connect() file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\urllib3\connection.py", line 326, in connect ssl_context=context) file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\urllib3\util\ssl_.py", line 315, in ssl_wrap_socket raise sslerror(e) urllib3.exceptions.sslerror: unknown error (_ssl.c:3510) during handling of above exception, exception occurred: traceback (most recent call last): file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\requests\adapters.py", line 440, in send timeout=timeout file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\urllib3\connectionpool.py", line 639, in urlopen _stacktrace=sys.exc_info()[2]) file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\urllib3\util\retry.py", line 388, in increment raise maxretryerror(_pool, url, error or responseerror(cause)) urllib3.exceptions.maxretryerror: httpsconnectionpool(host='controlpanel.peopleadmin.com', port=443): max retries exceeded url: /sessions/ (caused sslerror(sslerror(0, 'unknown error (_ssl.c:3510)'),)) during handling of above exception, exception occurred: traceback (most recent call last): file "c:/users/cody.jones/pycharmprojects/loginhandler/test.py", line 48, in <module> response = ses.post(url, values, verify='cert.cer') file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\requests\sessions.py", line 555, in post return self.request('post', url, data=data, json=json, **kwargs) file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\requests\sessions.py", line 508, in request resp = self.send(prep, **send_kwargs) file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\requests\sessions.py", line 618, in send r = adapter.send(request, **kwargs) file "c:\users\cody.jones\appdata\local\programs\python\python36-32\lib\site-packages\requests\adapters.py", line 506, in send raise sslerror(e, request=request) requests.exceptions.sslerror: httpsconnectionpool(host='controlpanel.peopleadmin.com', port=443): max retries exceeded url: /sessions/ (caused sslerror(sslerror(0, 'unknown error (_ssl.c:3510)'),))
my code
values = {'system_user[username]' : username, 'system_user[password]' : password, 'authenticity_token' : token } #begin session ses = requests.session() response = ses.post(url, values, verify='cert.cer')
i have copied ssl cert downloading data openssl. i'm still getting ton of errors , don't see doing wrong. i'm trying resolve issues ssl because when connect script on vpn (instead of being in actual office) has issue ssl verification. need software work regardless of whether or not you're on vpn since i'm on vpn.
wiki
Comments
Post a Comment