Forum Discussion
keegan_morrison
Nimbostratus
Oct 10, 2007ssl error when connecting from with php
Hi all. I'm working on writing an interface to display host information on our F5 in our company wiki. I'm trying to set up php to conenct to the f5, and i'm not having much luck.
I followed the php tutorial (http://devcentral.f5.com/Default.aspx?tabid=63&articleType=ArticleView&articleId=69).
Here's my setup:
- solaris 10 update 3
- php 5.2.4 (has soap installed)
- curl 7.17.0
- httpd 2.2.4
I have not compiled php or apache with ssl support.
Here's my source code:
require_once 'SOAP/Client.php';
$soapoptions = array('namespace' => 'urn:iControl');
$wsdl_url = 'http://localhost/bigip/iControl/sdk/wsdl/LocalLB.Pool.wsdl';
$proxy_parms = array( 'user' => $username, 'pass' => $password);
$params = array();
$client = new SOAP_Client($wsdl_url, true, '', $proxy_parms );
$client->setOpt('curl', CURLOPT_SSL_VERIFYPEER, 0);
$client->setOpt('curl', CURLOPT_SSL_VERIFYHOST, 0);
$response = $client->call('get_list', $params, $soapoptions);
if (PEAR::isError($response))
{
print "an error occurred in the call: ";
echo $response->message;
}
The error i get when i go to that page is:
curl_exec error 35 error:140943FC:SSL routines:SSL3_READ_BYTES:sslv3 alert bad record mac
WHen i googled, i didn't find much help. Does anyone know how to fix this? Should i try compiling with ssl support?
- I haven't used the php toolkit so I don't know for sure. The one thing that sticks out is that it looks like you are using the wsdl file for the connection endpoint information. If you are using the stock wsdl files in the SDK, they do not have a correct endpoint to the BIG-IP. You'll need to override the endpoint with https://bigip_address/iControl/iControlPortal.cgi.
- keegan_morrison
Nimbostratus
Edit: This issue has been resolved, please see the bottom of the next post - keegan_morrison
Nimbostratus
I've narrowed the problem down to being an OpenSSL issue. There are evidently problems with the version of openssl I installed (0.9.8b) and Solaris 10. Running openssl from teh command prompt with SSLv3 produced the following error:
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects