Difference between HTTP and HTTPS

The HTTP concept (Hypertext Transfer Protocol) is used to transmit information in plaintext between Web browsers and Web servers without providing any form of data encryption, so it is very insecure to use HTTP to transmit private information.

The HTTPS concept (Secure Socket Layer Hypertext Transfer Protocol) adds the SSL protocol to HTTP, which relies on SSL certificates to verify the identity of the server and to encrypt communication between the browser and the server.

CHttpDownload concept

A C++ low-level library

BOOL Initialize(CStringA strRemotePath, CStringA strLocalPath, BOOL bIsAppend, void * Userdata= NULL, PROCESS_CALLBACK ProcessCallback = NULL, DWORD dwMaxDownSpeed = 0, WRITE_DATA_CALLBACK WriteDataCallback = NULL); BOOL Start(); BOOL Stop(); BOOL NeedStop(); // Return immediatelyCopy the code

Question:

If your URL is HTTPS then this initialization will work, but it won’t request the data, so you have to change the URL, change HTTPS to HTTP so that you can access it safely

If you are accessing HTTPS for that long, turn off CA authentication and add the following two lines of code

curl_easy_setopt(curl, CURLOPT_SSL_VERIFYHOST, 0L);
curl_easy_setopt(curl, CURLOPT_SSL_VERIFYPEER, 0L);
Copy the code

Welcome to exchange: Shenzhen Programmer exchange group 550846167