Hello,
I would sugges setting CURLOPT_VERBOSE to 1 in the cURL Options to make the logging more verbose as suggested.
Also to emulate the -k option for curl, try setting these 2 also :
CURLOPT_SSL_VERIFYHOST to 1
CURLOPT_SSL_VERIFYPEER to 1
Mind that this will be less secure.
Also check the ciphers on the destination and Cloverleaf and see if they match.
We have had some challenges with connection to servers where ciphers on the destination were newer/more secure than
the ciphers available on Cloverleaf 6.2
Yours sincerely
Ib Højme