Python HTTPS requests - disable SSL verification

When using Python to implement certain REST APIs (like for SugarCRM, for example), if the development server is using a SSL certificate that is self-signed or otherwise untrusted, it may be necessary to disable the SSL verification as part of the request.

In my case, I was using the sugarcrm 0.1 wrapper and I had to edit the sugarcrm.py library file.

WARNING: the following modification is not upgrade-safe

# vi /usr/local/lib/python2.7/dist-packages/sugarcrm.py

Find the requests.post line

r = requests.post(self.url, data=data)

and add the verify=False parameter

r = requests.post(self.url, data=data, verify=False)

Now the SSL certificate verification will be skipped.