Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

St George/Bank of SA (Australia) integration


adrianbr

Recommended Posts

Hi,

 

I am currently having some trouble implementing the Bank of SA/St George payment module available from http://www.oscommerce.com/community/contri...l/search,george.

 

Is there anyone who has successfully installed this who might be able to provide me with some assistance?

 

In particular, I am getting the following error: "Error: While trying get(). Check init() and the location of the Webpay client .so file". This error appears to be triggered from the webpay_php.so file, so I can't see how there would be a problem with accessing that file.

 

 

 

Thanks,

 

Adrian

Link to comment
Share on other sites

No one has any ideas?

 

Part of the difficulty is that one component of this code has been compiled, so there is no obvious way I can determine where exactly the problem is occurring.

 

 

 

Hi,

 

I am currently having some trouble implementing the Bank of SA/St George payment module available from http://www.oscommerce.com/community/contri...l/search,george.

 

Is there anyone who has successfully installed this who might be able to provide me with some assistance?

 

In particular, I am getting the following error: "Error: While trying get(). Check init() and the location of the Webpay client .so file". This error appears to be triggered from the webpay_php.so file, so I can't see how there would be a problem with accessing that file.

Thanks,

 

Adrian

Link to comment
Share on other sites

Hey mate. I haven't used this module, nor do I intend to ;), but I thought I'd have a stab at it nonetheless.

 

I daresay it's failing around this area of code in includes/modules/payment/banksa.php:

 

if (!extension_loaded(BANKSA_PHP_LIB)) {
	if (!dl(BANKSA_PHP_LIB)) {
	tep_redirect(tep_href_link(FILENAME_CHECKOUT_PAYMENT, 'error_message=' . urlencode(MODULE_PAYMENT_BANKSA_TEXT_ERROR_LIB), 'SSL', true, false));
	exit;
	} 
}

 

I'd suggest having a look at the PHP website for some help in diagnosing this.

 

My guess is that enable_dl is turned off on your server. The other thing to consider is where code looks for the webpay_php.so file. The link I posted above has some info on that.

 

Hope this gives you a lead. Good luck. :)

Link to comment
Share on other sites

i have a problem with this module in that any transaction, no matter how dodgy the CC number entered is, comes back as approved...

 

the gateway is installed correctly as Ive tested it with the programs that come with it, its more an issue with the module or oscommerce I think...

any ideas?

Link to comment
Share on other sites

Thanks for the feedback, but I have still been unable to get this working.

 

I don't believe that enable_dl is the problem. You see the DL works fine and it loads the configuration file. The issue is when it connects with the bank SA and I get back that error message in the HTTP response.

 

The error occurs running this method:

 

//Send the transaction to the Transaction Server

$tranProcessed = executeTransaction( $webpayRef );

 

What happens is in the response variable ($tranProcessed) the error string is passed back which is displayed on the screen. The problem is the method this calls is in the compiled code: webpay_php.so which makes it impossible to debug. So it's hard to determine if the bank is being reached at all...

Link to comment
Share on other sites

powderbomber wrote: i have a problem with this module in that any transaction, no matter how dodgy the CC number entered is, comes back as approved...

 

Hey powderbomber from my experience with this module I'm assuming that you are connecting to the test system which from memory will approve transactions (as long as the card numbers pass basic mod checking) based on the cent value of the transaction. i.e. A $10.00 transaction will return a Response Code of 00 which is an Approved response. A $10.01 will return a Response Code of 01 which is a declined response.... (Refer to card issuer or something).

Link to comment
Share on other sites

adrianbr wrote: I am getting the following error: "Error: While trying get(). Check init() and the location of the Webpay client .so file". This error appears to be triggered from the webpay_php.so file, so I can't see how there would be a problem with accessing that file.

 

Hey adrian - I successfully ran this module on a machine that I had root privellege to ... if you dig deep enough you will find that the webpay_php.so file is just a php specific wrapper to a more generic libwebpay.so file.... from the error message I'm guessing that this file either is not in the /usr/lib directory or does not have the appropriate permissions - when I had a similar problem I re-read the doco and it made it pretty clear what needed to go where.

Link to comment
Share on other sites

Hey,

 

I'm also having troubles implementing this module, though it looks like it could work out.

 

My question are

 

-what type of webserver is this meant to live on and does it matter?

 

I'm running Linux/Apache so I'm not sure if it'll work.

 

-If I cannot place the webpay.so file in the /usr/lib directory how can I make the module look elsewhere? Recompile it?

 

thanks in advance for any help or pointers

 

Doug

Link to comment
Share on other sites

  • 9 months later...

I know this is an old post but all the posts I can find do not have the cause of the issue.

 

I stumbled on it by changing the test script to load forcefully load the libwebpayclient.so module using the dl() function (dynamic load) before the webpay_php.so module. The results gave a very important clue:

Warning: dl() [function.dl]: Unable to load dynamic library '/usr/lib/libwebpayclient.so' - libstdc++.so.5: cannot open shared object file: No such file or directory in /path_to_test_script/test.php on line 28
Starting webpay Transaction 
There has been an initialisation problem. Please check error log.

You will notice that there is a - libstdc++.so.5 that appears in the error message. Apparently another library being loaded at runtime! THIS is the file it can't find (unless you happen to have it installed already).

 

It is part of the compat-libstdc++-33.i386 package which I installed using

yum install compat-libstdc++-33.i386

 

Hope this helps someone else out and saves them the many hours I spent pouring over it.

 

:thumbsup:

Link to comment
Share on other sites

  • 6 months later...
I installed using
yum install compat-libstdc++-33.i386

 

Hope this helps someone else out and saves them the many hours I spent pouring over it.

 

:thumbsup:

 

 

Thanks a million Pandah. This certainly did save me a few hours, worked like a charm :).

 

Thanks

 

Stats

Link to comment
Share on other sites

  • 3 years later...

I know this is an old thread but I had to update an old system of mine running this API, and came back to this thread, when I hit a similar problem.

The trick this time around was to check the dependencies on the libwebpayclient library:

 

ldd libwebpayclient.so

 

It is looking for specific version of libssl and libcrypto. Creating symlinks to these specific versions fixed the problem and everything worked like a charm:

 

cd /usr/lib/i386-linux-gnu

sudo ln -s libssl.so.1.0.0 libssl.so.6

sudo ln -s libcrypto.so.1.0.0 libcrypto.so.6

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...