From: Anthony Minessale Date: Tue, 19 Aug 2008 14:52:44 +0000 (+0000) Subject: enable https on mod_xml_cdr X-Git-Tag: v1.0.2~1414 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=18a93b2ff89dbd1d462973f80c029e257a5a2a27;p=thirdparty%2Ffreeswitch.git enable https on mod_xml_cdr git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@9321 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- diff --git a/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c b/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c index cb8ba16fd7..55faccf1ab 100644 --- a/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c +++ b/src/mod/xml_int/mod_xml_cdr/mod_xml_cdr.c @@ -141,6 +141,11 @@ static switch_status_t my_on_hangup(switch_core_session_t *session) headers = curl_slist_append(headers, "Content-Type: application/x-www-form-plaintext"); } + if (!strncasecmp(globals.url, "https", 5)) { + curl_easy_setopt(curl_handle, CURLOPT_SSL_VERIFYPEER, 0); + curl_easy_setopt(curl_handle, CURLOPT_SSL_VERIFYHOST, 0); + } + if (!(curl_xml_text = switch_mprintf("cdr=%s", xml_text))) { switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_CRIT, "Memory Error!\n"); goto error;