Curl With Certificates As Strings

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello!

Can Curl be configured to use SSL certificates in strings, rather than in files?  I am storing my user's certificates in a mySQL database, and I don't really want to write those certificates to a file, and then use the file, and then delete them when I'm done.  I would much rather just pass the certificate to Curl as a string instead.

For example, instead of:

curl_setopt($Curl, CURLOPT_SSLCERT, "/tmp/cert.pem");

I would like to do:

$UserQuery = mysql_query("select * from Users where ID = 1000", $Database);
$UserRow = mysql_fetch_assoc($UserQuery);
curl_setopt($Curl, CURLOPT_SSLCERT, $UserRow["Certificate"]);

Is that possible?  If it isn't using Curl, is there some other library I could use to accomplish this?  All I need to do is simple HTTPS posts and gets.

Tim Gustafson
MEI Technology Consulting, Inc
tjg@xxxxxxxxxxx
(516) 379-0001 Office
(516) 908-4185 Fax
http://www.meitech.com/ 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux