X-Git-Url: http://Server1/repobrowser/?p=xestiaab%2F.git;a=blobdiff_plain;f=source%2Fcarddav2%2Fcarddav2.cpp;h=dd70bab9a6c030ebd5843fc61efef84eac3545dc;hp=f4041b85ecf2a28b2331d5b7712a316c4cf68c17;hb=f61e0e5b738c51d4b4b7e329c1e31fb2a9b3e2c9;hpb=e8efcf96e52c4d8d82ded85327070dcb7a4e3609 diff --git a/source/carddav2/carddav2.cpp b/source/carddav2/carddav2.cpp index f4041b8..dd70bab 100644 --- a/source/carddav2/carddav2.cpp +++ b/source/carddav2/carddav2.cpp @@ -156,8 +156,6 @@ SSLCertCollectionString CardDAV2::BuildSSLCollection(){ // Build and return the SSL collection. - cout << "Build SSL Collection!" << endl; - SSLCertCollectionString SSLCertInfo; // Grab the certificate data. @@ -170,8 +168,6 @@ SSLCertCollectionString CardDAV2::BuildSSLCollection(){ certptr.certdata = NULL; CURLcode result = curl_easy_getinfo(ConnectionSession, CURLINFO_CERTINFO, &certptr.certinfo); - - cout << certptr.certinfo->num_of_certs << endl; std::string CertPropName; std::string CertPropValue; @@ -251,6 +247,7 @@ COConnectResult CardDAV2::Connect(bool DoAuthentication){ SSLVerified = COSSL_VERIFIED; ConnectResult = COCONNECT_OK; break; + case CURLE_SSL_INVALIDCERTSTATUS: case CURLE_SSL_CACERT: case CURLE_SSL_CONNECT_ERROR: SSLStatus = true; @@ -1272,8 +1269,6 @@ COContactList CardDAV2::GetContactList(std::string SyncToken){ std::string SyncData; - // TODO: Copy old code from CardDAV class as needed. - if (SyncToken.size() > 0){ SyncData = "\n" @@ -1496,9 +1491,12 @@ void CardDAV2::SetupDefaultParametersSSL(bool DoAuthentication){ string CertificateFilename = GetAccountDir(ServerAccount, true); if (wxFile::Exists(CertificateFilename)){ - + curl_easy_setopt(ConnectionSession, CURLOPT_CAINFO, CertificateFilename.c_str()); + // Force CURLOPT_SSL_VERIFYSTATUS to 0. + curl_easy_setopt(ConnectionSession, CURLOPT_SSL_VERIFYSTATUS, 0L); + } }