Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Fixed curl ssl invalid cert file #46

Merged
merged 1 commit into from

2 participants

@dosercz

Added curl errno 77 for loading cert file

@gfosco
Collaborator

Sorry it took so long to respond to this. Can you sign the Contributor License Agreement? https://developers.facebook.com/opensource/cla

Once that's done we can look at merging this. Thanks for your contribution.

@dosercz

CLA is signed

@gfosco
Collaborator

Thanks for your contribution Dominik!

@gfosco gfosco merged commit e90d402 into from
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Nov 30, 2012
  1. @dosercz
This page is out of date. Refresh to see the latest.
Showing with 4 additions and 2 deletions.
  1. +4 −2 src/base_facebook.php
View
6 src/base_facebook.php
@@ -935,8 +935,10 @@ protected function makeRequest($url, $params, $ch=null) {
curl_setopt_array($ch, $opts);
$result = curl_exec($ch);
-
- if (curl_errno($ch) == 60) { // CURLE_SSL_CACERT
+
+ $errno = curl_errno($ch);
+ // CURLE_SSL_CACERT || CURLE_SSL_CACERT_BADFILE
+ if ($errno == 60 || $errno == 77) {
self::errorLog('Invalid or no certificate authority found, '.
'using bundled information');
curl_setopt($ch, CURLOPT_CAINFO,
Something went wrong with that request. Please try again.