Robert Schweikert
0f6946c0d7
- update no-default-cacert.patch to simply pass empty CA path - urllib3-ssl-default-context.patch: patch bundled urllib3 to behave correctly with regard to empty CA path passed - change urllib3 fallback requirements to Recommends - use ca-certificates in SLE as well - recommend ca-certificates-mozilla to have a basic certificate set OBS-URL: https://build.opensuse.org/request/show/373395 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-requests?expand=0&rev=87
14 lines
510 B
Diff
14 lines
510 B
Diff
Index: b/urllib3/util/ssl_.py
|
|
===================================================================
|
|
--- a/urllib3/util/ssl_.py
|
|
+++ b/urllib3/util/ssl_.py
|
|
@@ -299,6 +299,8 @@ def ssl_wrap_socket(sock, keyfile=None,
|
|
if e.errno == errno.ENOENT:
|
|
raise SSLError(e)
|
|
raise
|
|
+ elif cert_reqs != ssl.CERT_NONE and hasattr(context, 'set_default_verify_paths'):
|
|
+ context.set_default_verify_paths()
|
|
|
|
if certfile:
|
|
context.load_cert_chain(certfile, keyfile)
|