curl / Mailing Lists / curl-library / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

https: curl_easy_perform() failed: Unsupported protocol

From: Julien Matthey via curl-library <curl-library_at_lists.haxx.se>
Date: Tue, 12 Apr 2022 19:07:51 +0200

I get "curl_easy_perform() failed: Unsupported protocol" for https requests:

Example:


#include <curl/curl.h>

int main(int argc, char** argv) {

     CURL* curl;
     CURLcode res;
     curl_global_init(CURL_GLOBAL_ALL);
     curl = curl_easy_init();

     if (curl) {
         curl_easy_setopt(curl, CURLOPT_URL, "https://www.google.com");
         res = curl_easy_perform(curl);
         if (res != CURLE_OK)
             fprintf(stderr, "curl_easy_perform() failed: %s\n",
curl_easy_strerror(res));

         curl_easy_cleanup(curl);
     }
     curl_global_cleanup();

     return 0;
}


And here is my problem with it: it works with the curl.exe executable I
also built! Example:

$curl *https*://www.google.com

The *https *request WILL SUCCEED! -> connected through port 403 and the
page contents are printed.

So why doesn't it work in my own sample project?

Here is my cmake SSL configuration:

-Julien


-- 
Unsubscribe: https://lists.haxx.se/listinfo/curl-library
Etiquette:   https://curl.haxx.se/mail/etiquette.html
Received on 2022-04-12