function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
phyroslam2phyroslam2 

php toolkit without openssl and sokets

I have a hosting provider and even they have php 5.1.4 installed they don´t have activated openssl and socket extensions. Does the leatest php toolkit can work without them and which are the risk if there are any ?

Thank you
Tran ManTran Man
You will have to modify the toolkit to make http calls rather than https.  There are many articles on SSL but the main benefit is that it allows for a secure transmission of your data.  Without it your data is at risk of being intercepted.


There are many hosting providers that provide SSL.  Would you be able to switch?

Message Edited by Tran Man on 07-07-2006 09:25 AM

ramgtramgt
Hi,
I also have the same issue. My current hosting provider is GoDaddy and they provide PHP5.1.4 but do not have openssl.
 
1. Can you please guide me where exactly do we need to make the changes to use http assuming i am not greatly bothered about secure connection at this time.
2. Can you suggest and alternate web hosting provider that would provide all that is required with  shared web hosting?
 
An early reply will be highly appreciated.
 
Regards,
Ram
Tran ManTran Man
We would never recommend that you use the API without SSL, but here is how you would change HTTPS to HTTP in the toolkit:

In the SforceBaseClient.php file, modify setEndPoint to replace https with http in the server URL.

Code:
  public function setEndpoint($location) {
    $location = str_ireplace("https", "http", $location );
    $this->location = $location;
    $this->sforce->__setLocation($location);
  }

 

Message Edited by Tran Man on 07-07-2006 09:50 AM

Tran ManTran Man
This is not an endorsement but I believe dreamhost.com allows you to build PHP which should allow you to compile with OpenSSL support.

ramgt wrote:
Hi,
I also have the same issue. My current hosting provider is GoDaddy and they provide PHP5.1.4 but do not have openssl.
 
1. Can you please guide me where exactly do we need to make the changes to use http assuming i am not greatly bothered about secure connection at this time.
2. Can you suggest and alternate web hosting provider that would provide all that is required with  shared web hosting?
 
An early reply will be highly appreciated.
 
Regards,
Ram



ramgtramgt

Hi Nick,

Thanks for the quick response. I tried this approach but i keep getting the error "SSL support is not available in this build" during login from login.php script from the samples folder of the toolkit.

Looks like we do not explicitly set the endpoint during login. We just seem to give the wsdl file (partner.wsdl.xml) as input. I even tried changing the soap address in the WSDL file but it still kept showing the same error.

Can you please guide me as what could be going wrong in my implementation?

Regards,
Ram

Tran ManTran Man
I forgot one other method:

Code:
  private function _setLoginHeader($loginResult) {
$this->sessionId = $loginResult->sessionId;
$this->setSessionHeader($this->sessionId);
$serverURL = $loginResult->serverUrl;
$this->setEndPoint($serverURL);

}

 

ramgtramgt

Hi Nick,

The error seems to be occuring even before we set the login header. It happens at

$result = $this->sforce->login(array (

'username' => $username,

'password' => $password

));

How does this method work? I guess it makes a SSL call for login? Is there a workaround for this?

Regards,
Ram