forked from science-ation/science-ation
Don't verify the SSL certificate - temporary workaround for CURL's ca-cert bundle not properly authetnicating the YSF SSL cert.
This commit is contained in:
parent
bf58a9d78b
commit
91270b79ac
@ -72,14 +72,16 @@
|
||||
curl_setopt ($ch, CURLOPT_POSTFIELDSIZE, 0);
|
||||
curl_setopt ($ch, CURLOPT_TIMEOUT, 360);
|
||||
curl_setopt ($ch, CURLOPT_SSLVERSION, 3);
|
||||
curl_setopt ($ch, CURLOPT_SSL_VERIFYPEER, false);
|
||||
$datastream = curl_exec ($ch); /// execute the curl session and return the output to a variable $datastream
|
||||
$datastream = str_replace(" standalone=\"yes\"","",$datastream);
|
||||
// echo "curl close <br />";
|
||||
curl_close ($ch); /// close the curl session
|
||||
// echo "sending [".nl2br(htmlspecialchars($xmldata))."]";
|
||||
|
||||
echo i18n("The Remote Server said:")."<br />";
|
||||
//echo notice($datastream);
|
||||
$response=xml_parsexml($datastream);
|
||||
if(is_array($response)) {
|
||||
$keys=array_keys($response);
|
||||
if($keys[0]=="awardresponse") {
|
||||
|
||||
@ -298,6 +300,9 @@ echo mysql_error();
|
||||
}
|
||||
else
|
||||
echo error(i18n("Invalid XML response. Expecting '%1', received '%2'",array("awardresponse",$keys[0])));
|
||||
}
|
||||
else
|
||||
echo error(i18n("Invalid response. Could not parse XML into Array: %1",array($response)));
|
||||
// echo "response=".print_r($datastream);
|
||||
|
||||
echo "<br />";
|
||||
|
Loading…
Reference in New Issue
Block a user