2015-07-10 14:18:52 +02:00
|
|
|
Index: requests-2.6.0/requests/adapters.py
|
|
|
|
===================================================================
|
|
|
|
--- requests-2.6.0.orig/requests/adapters.py
|
|
|
|
+++ requests-2.6.0/requests/adapters.py
|
|
|
|
@@ -177,9 +177,6 @@ class HTTPAdapter(BaseAdapter):
|
2013-07-25 14:57:44 +02:00
|
|
|
if not cert_loc:
|
|
|
|
cert_loc = DEFAULT_CA_BUNDLE_PATH
|
|
|
|
|
|
|
|
- if not cert_loc:
|
|
|
|
- raise Exception("Could not find a suitable SSL CA certificate bundle.")
|
|
|
|
-
|
|
|
|
conn.cert_reqs = 'CERT_REQUIRED'
|
|
|
|
conn.ca_certs = cert_loc
|
|
|
|
else:
|
2015-07-10 14:18:52 +02:00
|
|
|
Index: requests-2.6.0/requests/certs.py
|
|
|
|
===================================================================
|
|
|
|
--- requests-2.6.0.orig/requests/certs.py
|
|
|
|
+++ requests-2.6.0/requests/certs.py
|
|
|
|
@@ -18,8 +18,9 @@ try:
|
|
|
|
except ImportError:
|
2014-09-11 17:26:41 +02:00
|
|
|
def where():
|
|
|
|
"""Return the preferred certificate bundle."""
|
2015-07-10 14:18:52 +02:00
|
|
|
- # vendored bundle inside Requests
|
2014-09-11 17:26:41 +02:00
|
|
|
- return os.path.join(os.path.dirname(__file__), 'cacert.pem')
|
2015-07-10 14:18:52 +02:00
|
|
|
+ # in openSUSE we rely on openssl's default instead of
|
|
|
|
+ # hardcoding stuff elsewhere
|
|
|
|
+ return None
|
2013-07-25 14:57:44 +02:00
|
|
|
|
|
|
|
if __name__ == '__main__':
|
|
|
|
print(where())
|
2015-07-10 14:18:52 +02:00
|
|
|
Index: requests-2.6.0/MANIFEST.in
|
|
|
|
===================================================================
|
|
|
|
--- requests-2.6.0.orig/MANIFEST.in
|
|
|
|
+++ requests-2.6.0/MANIFEST.in
|
2013-07-25 14:57:44 +02:00
|
|
|
@@ -1 +1 @@
|
|
|
|
-include README.rst LICENSE NOTICE HISTORY.rst test_requests.py requirements.txt requests/cacert.pem
|
|
|
|
+include README.rst LICENSE NOTICE HISTORY.rst test_requests.py requirements.txt
|
2015-07-10 14:18:52 +02:00
|
|
|
Index: requests-2.6.0/requests/packages/urllib3/util/ssl_.py
|
|
|
|
===================================================================
|
|
|
|
--- requests-2.6.0.orig/requests/packages/urllib3/util/ssl_.py
|
|
|
|
+++ requests-2.6.0/requests/packages/urllib3/util/ssl_.py
|
|
|
|
@@ -259,6 +259,9 @@ def ssl_wrap_socket(sock, keyfile=None,
|
|
|
|
if e.errno == errno.ENOENT:
|
|
|
|
raise SSLError(e)
|
|
|
|
raise
|
|
|
|
+ elif cert_reqs != CERT_NONE:
|
|
|
|
+ context.set_default_verify_paths()
|
|
|
|
+
|
|
|
|
if certfile:
|
|
|
|
context.load_cert_chain(certfile, keyfile)
|
|
|
|
if HAS_SNI: # Platform-specific: OpenSSL with enabled SNI
|