Send data securely via curl

As long as I tested it seems curl has nothing to do with separated openssl extension, but I guess it has its own openssl as appears under curl extension in phpinfo.
with extension_exists this is possible to check whether curl is installed, but how can I check with php whether curl has openssl or ssl support?