rmccue/Requests — pull request #55 by kacer (2013-05-28 11:00:58+00:00)
Title: Verify SSL certificate when using cURL

I feel that silently disabling SSL verification by default (as it is done in the cURL transport) is a very, very bad idea.

This requests re-enables the verification by default. If for some reason the user needs to disable the check, it can be done via the `verify` option (as it is done in the Python Requests library). The verify option can be set either to `false` (to disable the checks) or to path to a file containing trusted CA certificates (`CURLOPT_CAINFO`).

I also added another option, not present in the python library - `verifyname`. If set to `false`, it won't check whether the certificate holder name equals to the remote host name (`CURLOPT_SSL_VERIFYHOST` option).

I didn't add the support of these options to the `multi_request` method, since I don't know how to do it - the `curl_ multi_ setopt` function is not documented at all.