www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 9737] New: std.net.curl and SSL - documentation missing


           Summary: std.net.curl and SSL - documentation missing
           Product: D
           Version: D2
          Platform: All
        OS/Version: Windows
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Phobos
        AssignedTo: nobody puremagic.com
        ReportedBy: octavian.cacina outlook.com

--- Comment #0 from Tavi Cacina <octavian.cacina outlook.com> 2013-03-16
10:35:40 PDT ---
I wanted to use std.net.curl to make a simple request over SSL, for ex.
get("https://google.com"). It failed with the message "Peer certificate cannot
be authenticated with given CA certificates". In documentation I could not find
anything, so it was a tedious search for something that has actually an easy
resolution. Since this is a quite common usage scenario, it should be
documented. Also note that the HTTP.caInfo does not have any doc entry. 

SSL usage example:
auto http = HTTP();

// Set the CA certificate bundle file to use for SSL peer verification
// To dowload this file (or generate it yourself) see
// For more information about SSL peer verification see

//http.handle.set(CurlOption.ssl_verifypeer, 0); // do not verify ssl
certifiactes, use with care!

auto resp = get("https://google.com", http);

Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Mar 16 2013