stream_context_set_option出现奇怪错误

时间:2010-12-10 14:17:53

标签: php ssl pem

我想连接ssl Server。我用stream_context_set_option附上了ssl证书。

但它会返回"check that your cafile/capath settings include details of your certificate".

$apnsCert = 'apns-dev.pem';
stream_context_set_option($streamContext, 'ssl', 'local_cert', 
                          dirname(__FILE__).'/'.$apnsCert);

apns-dev.pem在同一个文件夹中。

如果我添加,在顶部,它运作良好。我不明白。 证书文件的许可是644

0 个答案:

没有答案
相关问题