我正嘗試使用php和curl庫下載安全(使用https)網頁的內容。使用CURL讀取SSL頁面(php)
但是,讀取失敗,並且出現錯誤60:「SSL證書問題,請驗證CA證書是否正常。」
還 「詳細信息:SSL3_GET_SERVER_CERTIFICATE:證書驗證失敗」
所以...非常自我解釋錯誤味精的。
我的問題是:如何發送SSL證書(正確的?)並獲取此頁來驗證它並讓我進入?
而且,這裏是我的選擇數組中如果你想知道:
$options = array(
CURLOPT_RETURNTRANSFER => true, // return web page
CURLOPT_HEADER => false, // don't return headers
CURLOPT_FOLLOWLOCATION => true, // follow redirects
CURLOPT_ENCODING => "", // handle all encodings
CURLOPT_USERAGENT => "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:x.x.x) Gecko/20041107 Firefox/x.x", // who am i
CURLOPT_AUTOREFERER => true, // set referer on redirect
CURLOPT_CONNECTTIMEOUT => 120, // timeout on connect
CURLOPT_TIMEOUT => 120, // timeout on response
CURLOPT_MAXREDIRS => 10, // stop after 10 redirects
CURLOPT_SSL_VERIFYHOST => 1,
);
任何建議將是巨大的, 安德魯
想想[本條](http://curl.haxx.se/docs/sslcerts。 HTML)是你需要的。 – Sergii 2009-02-06 18:05:51