flask-oauth
flask-oauth copied to clipboard
Add ability to include additional CA certs for SSL requests
In working with an OAuth endpoint that used SSL, I discovered that the certifying authority’s certificate (Network Solutions in this case) was not included in the cacerts.txt file that ships with httplib2. This is a simple patch which adds a configuration parameter to the initial setup that allows passing in a path to a pem file that contains additional certificates.
There are few CA's missing from the list bundled by httplib2. It would be safe to replace the list with Mozilla accepted list, which is available in package certifi (line 197):
self._client = OAuthClient(self._consumer)
self._client.ca_certs = certifi.where()