开发者

facebook API problem with IIS7

开发者 https://www.devze.com 2023-01-27 02:21 出处:网络
I\'m having problems with the facebook example code. Fatal error: Uncaught CurlException: 60: SSL certificate problem, verify that the CA cert is OK. Details: error:14090086:SSL routines:SSL3_GET_SE

I'm having problems with the facebook example code.

Fatal error: Uncaught CurlException: 60: SSL certificate problem, verify that the CA cert is OK. Details: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed thrown in C:\inetpub\wwwroot\src\facebook.php on line 616

I found a solution that I don't know wha开发者_JAVA百科t to do with here. I'm running IIS7 and trying to test this on localhost. The solution specified that I should add

$opts[CURLOPT_CAINFO] = [PATH]/apache/conf/ssl.crt/ca-bundle.crt"; //Or your path to "ca-bundle.crt"

to the code. I found the array where this info should go but I have absolutely no idea where the certificates are stored. I searched my machine for my self-signed cert ("myown") but couldn't find it. I googled for the location of cert files on IIS7 but realized I'd be better of here since maybe I don't even need to specify SSL certs.

Any suggestions? What I want to do is just to be able to run the code, I don't have any requirements of SSL right now.


i think that the certificate is being returned but can not be validated, within C# you can usually do something like so:

ServicePointManager.ServerCertificateValidationCallback = delegate{
    return true;
};

so this is a callback that's executed before the certificate is validate and acts as a user validation method.

WARNING: this will validate all certificates regardless

never used IIS but im sure it would be something along these lines.

0

精彩评论

暂无评论...
验证码 换一张
取 消