Reputation: 345
Trying to access the URL https://memphis.ulbranet.com.br/ALEPH/ using cURL in PHP, but it presents the following error:
bool (false) string (80) "error: 14077417: SSL routines: SSL23_GET_SERVER_HELLO: SSLv3 alert illegal parameter"
Anyone know why?
<?php
ini_set( 'display_errors' , true );
error_reporting( E_ALL );
$curl = curl_init();
curl_setopt( $curl , CURLOPT_URL , 'https://memphis.ulbranet.com.br/ALEPH/' );
curl_setopt( $curl , CURLOPT_RETURNTRANSFER , true );
curl_setopt( $curl , CURLOPT_SSL_VERIFYPEER , false );
var_dump( curl_exec( $curl ) , curl_error( $curl ) );
Upvotes: 2
Views: 333
Reputation: 28795
I'm not sure whether this is a bug in CURL, an incorrectly formatted SSL setup or a version compatibility - but you can fix it by telling CURL to use SSL version 3:
curl_setopt($ch, CURLOPT_SSLVERSION, 3);
Upvotes: 4