configCurlCertificate() public static method

Will configure CURL handle $ch to use local list of Certificate Authorities,
public static configCurlCertificate ( &$ch )
Exemplo n.º 1
0
 private function getNewCurlHandle($url)
 {
     $ch = curl_init($url);
     curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
     if ($this->acceptInvalidSSLCertificate) {
         curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);
         curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
     }
     curl_setopt($ch, CURLOPT_USERAGENT, Http::getUserAgent());
     Http::configCurlCertificate($ch);
     return $ch;
 }