explicitly pass certificate-bundle path to curl

This commit is contained in:
Joe Bryan 2019-07-11 16:43:46 -07:00
parent 86590c477c
commit 75556e2367
2 changed files with 7 additions and 4 deletions

View File

@ -466,6 +466,7 @@ _daemon_get_atom(c3_c* url_c)
exit(1);
}
curl_easy_setopt(curl, CURLOPT_CAINFO, u3K.certs_c);
curl_easy_setopt(curl, CURLOPT_URL, url_c);
curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, _daemon_curl_alloc);
curl_easy_setopt(curl, CURLOPT_WRITEDATA, (void*)&buf_u);

View File

@ -78,8 +78,9 @@ _dawn_post_json(c3_c* url_c, uv_buf_t lod_u)
hed_u = curl_slist_append(hed_u, "Content-Type: application/json");
hed_u = curl_slist_append(hed_u, "charsets: utf-8");
// XX require TLS, pin default cert?
// XX require TLS, pin default cert?
//
curl_easy_setopt(curl, CURLOPT_CAINFO, u3K.certs_c);
curl_easy_setopt(curl, CURLOPT_URL, url_c);
curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, _dawn_curl_alloc);
curl_easy_setopt(curl, CURLOPT_WRITEDATA, (void*)&buf_u);
@ -124,8 +125,9 @@ _dawn_get_jam(c3_c* url_c)
exit(1);
}
// XX require TLS, pin default cert?
// XX require TLS, pin default cert?
//
curl_easy_setopt(curl, CURLOPT_CAINFO, u3K.certs_c);
curl_easy_setopt(curl, CURLOPT_URL, url_c);
curl_easy_setopt(curl, CURLOPT_WRITEFUNCTION, _dawn_curl_alloc);
curl_easy_setopt(curl, CURLOPT_WRITEDATA, (void*)&buf_u);