From: Ed Bartosh Date: Wed, 25 Mar 2015 09:59:55 +0000 (+0200) Subject: Completely ignore the internal CA bundle X-Git-Tag: v2.0.2~2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=22977ad4583a537f4c6a9f5b5dd1dd250482cdac;p=services%2Fpython-requests.git Completely ignore the internal CA bundle Imported no-default-cacert.patch from build.opensuse.org Signed-off-by: Ed Bartosh --- diff --git a/MANIFEST.in b/MANIFEST.in index 439de49..7888aee 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -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 diff --git a/requests/adapters.py b/requests/adapters.py index 0adca69..954dbb7 100644 --- a/requests/adapters.py +++ b/requests/adapters.py @@ -132,9 +132,6 @@ class HTTPAdapter(BaseAdapter): 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: diff --git a/requests/certs.py b/requests/certs.py index bc00826..90d0fa5 100644 --- a/requests/certs.py +++ b/requests/certs.py @@ -18,7 +18,7 @@ import os.path def where(): """Return the preferred certificate bundle.""" # vendored bundle inside Requests - return os.path.join(os.path.dirname(__file__), 'cacert.pem') + return '/etc/ssl/certs/' if __name__ == '__main__': print(where())