1
0
Fork 0
mirror of https://github.com/deltachat/deltachat-core.git synced 2025-10-05 02:29:28 +02:00

allow curl to perform "insecure" SSL connections

allow curl to perform "insecure" SSL connections using flag '--insecure'
Without this flag, curl exited with error 51: The peer's SSL certificate or SSH MD5 fingerprint was not OK.
autoconfig attempts to https URL did not succeed.
This commit is contained in:
Ampli-fier 2018-03-31 23:38:14 +02:00 committed by GitHub
parent 5000e17b92
commit 87759cf4da
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -81,7 +81,7 @@ static uintptr_t receive_event(mrmailbox_t* mailbox, int event, uintptr_t data1,
{
char* ret = NULL;
char* tempFile = mr_get_fine_pathNfilename(mailbox->m_blobdir, "curl.result");
char* cmd = mr_mprintf("curl --silent --location --fail %s > %s", (char*)data1, tempFile); /* --location = follow redirects */
char* cmd = mr_mprintf("curl --silent --location --fail --insecure %s > %s", (char*)data1, tempFile); /* --location = follow redirects */
int error = system(cmd);
if( error == 0 ) { /* -1=system() error, !0=curl errors forced by -f, 0=curl success */
size_t bytes = 0;