OctoPrint upload: ignore certificate revocation checks

Fixes Hostname incorrect While test is positive (Bonjour discovery not
supported for the address field) #1781
(partial fix of #1781)
This commit is contained in:
Vojtech Bubnik
2021-08-24 11:24:48 +02:00
parent 3acd12c3ba
commit feacd191ee
7 changed files with 35 additions and 3 deletions

View File

@@ -491,6 +491,14 @@ Http& Http::form_add_file(const std::string &name, const fs::path &path, const s
return *this;
}
Http& Http::revoke_best_effort(bool set)
{
if(p && set){
::curl_easy_setopt(p->curl, CURLOPT_SSL_OPTIONS, CURLSSLOPT_REVOKE_BEST_EFFORT);
}
return *this;
}
Http& Http::set_post_body(const fs::path &path)
{
if (p) { p->set_post_body(path);}