Development

Changeset 9049

You must first sign up to be able to contribute.

Changeset 9049

Show
Ignore:
Timestamp:
05/19/08 13:18:01 (5 years ago)
Author:
Gilles.Taupenas
Message:

added curl options support for ssl authentication

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • plugins/sfWebBrowserPlugin/lib/sfCurlAdapter.class.php

    r8592 r9049  
    6161    curl_setopt($this->curl, CURLOPT_FOLLOWLOCATION, false); 
    6262    curl_setopt($this->curl, CURLOPT_FRESH_CONNECT, true); 
    63  
     63     
     64    if(isset($this->options['follow_location'])) 
     65    { 
     66      curl_setopt($this->curl, CURLOPT_FOLLOWLOCATION, (bool) $this->options['follow_location']); 
     67    } 
     68     
    6469    // activate ssl certificate verification? 
     70     
     71    if (isset($this->options['ssl_verify_host'])) 
     72    { 
     73      curl_setopt($this->curl, CURLOPT_SSL_VERIFYHOST, (bool) $this->options['ssl_verify_host']); 
     74    } 
    6575    if (isset($this->options['ssl_verify'])) 
    6676    { 
     
    7484    } 
    7585 
    76     if (isset($this->options['verbose_log'])) 
     86    if(isset($this->options['verbose_log'])) 
    7787    { 
    7888      $log_file = sfConfig::get('sf_log_dir').'/sfCurlAdapter_verbose.log'; 
     
    105115    $request_headers = explode("\r\n", $browser->prepareHeaders($m_headers)); 
    106116    curl_setopt($this->curl, CURLOPT_HTTPHEADER, $request_headers); 
    107  
     117    
    108118    // encoding support 
    109119    if(isset($headers['Accept-Encoding']))