Paypal Payments Advanced - Weird error situation

  • Posts: 31
  • Thank you received: 1
8 years 6 months ago #239199

-- HikaShop version -- : 2.6.2
-- PHP version -- : 5.4.23
-- Browser(s) name and version -- : Chrome, not browser related
-- Error-message(debug-mod must be tuned on) -- : x
Message
Notification refused because of wrong secret code given :

Formatted in exactly that way ..

This says that I don't have the latest version yet Hikashop states "You have the latest stable version of HikaShop Business: 2.6.2" so I will proceed with the question..

The customers seem to be getting charged twice.. Before this was happening the iframe was actually giving a 404 error and I noticed something odd.

PayPal used to return them to a file called paypaladvanced_2.php but I noticed that now it was trying to return them to paypaladvanced_return_2.php for some strange reason, and that file didn't exist. So I tried just copying paypaladvanced_2.php to paypaladvanced_return_2.php .. that's when I noticed these errors showing up in the iframe.

I've attached a screenshot

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 82867
  • Thank you received: 13373
  • MODERATOR
8 years 6 months ago #239245

Hi,

I tried to reproduce the problem on your website but I'm not seeing shipping methods:
take.ms/fQoyH

Regarding the error you have, there should actually be a third file paypaladvanced_2_{secret_code}.php
That file is generated automatically for you when you save the PayPal Advanced payment method in your backend.
If you don't get it, it means that your root folder is not writable. Please make sure that it is and try again.

Please Log in or Create an account to join the conversation.

  • Posts: 31
  • Thank you received: 1
8 years 6 months ago #239253

I don't know why you wouldn't be seeing shipping methods, they are there.. it's your software, you tell me why you wouldn't be seeing them :) I'm using your UPS plugin ;) ( see attached )

But yes the directory is writeable.. and as I mentioned the site had been running flawlessly for months.. it's not a directory permissions issue.. Paypal had never been trying to go back to paypaladvanced_return_2.php before and suddenly it started doing that.. which resulted in 404 errors .. so what do I need to do to resolve this? any thoughts whatsoever?

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 31
  • Thank you received: 1
8 years 6 months ago #239258

I just went in and re-saved the settings and two new files that NEVER existed appeared..

paypaladvanced_cancel_2.php
paypaladvanced_return_2.php

I know those never existed because I went back to our backups and they aren't present from weeks back... I'm assuming there was an update at some point that added these? .. in that case, people who upgraded and didn't go in and edit the plugin would be experiencing issues... I know the paypal advanced plugin isn't hugely popular ( I argued against them using it ) so this could be a bug.. at any rate, this may have resolved the issue

Please Log in or Create an account to join the conversation.

  • Posts: 82867
  • Thank you received: 13373
  • MODERATOR
8 years 6 months ago #239269

Hi,

Yes, saving the configuration of the payment method is indeed the way to generate the files in the root folder as I said in my last message.
That modification has been done more than a year ago to increase the security of the notifications. So almost everyone who could have had the problem after the update has already updated by now.

Please Log in or Create an account to join the conversation.

  • Posts: 31
  • Thank you received: 1
8 years 6 months ago #239305

That's odd, the site is less than a year old by a long shot and it's only .1 version behind. It's been working flawlessly for several months.. why would that be? I see that particular plugin was modified on April 18th, not by us .. I guess I'm confused why those files never existed since it's a fairly new site.. and the issue only just came up over the last several days.

At any rate, I am glad that saving fixed it.. but the reason I said it seems like a bug is because anyone upgrading Hikashop wouldn't know that they need to go edit it and click save.. and it's unlikely people would even think to go try to edit a working configuration.. does that make sense?

Please Log in or Create an account to join the conversation.

  • Posts: 82867
  • Thank you received: 13373
  • MODERATOR
8 years 6 months ago #239331

Hi,

Yes, that makes sense. But as I said, (I've checked the SVN logs on our end before posting my previous message) that is an old change so most people who would have had the problem already had it which is why we didn't bother changing the way it's done, especially since the change would be complex to have the system generate the files elsewhere than when saving the settings of the payment method.

Please Log in or Create an account to join the conversation.

  • Posts: 31
  • Thank you received: 1
8 years 6 months ago #239349

nicolas wrote: Hi,

Yes, that makes sense. But as I said, (I've checked the SVN logs on our end before posting my previous message) that is an old change so most people who would have had the problem already had it which is why we didn't bother changing the way it's done, especially since the change would be complex to have the system generate the files elsewhere than when saving the settings of the payment method.


Well my questions remain... our install was just one revision old... .. the plugin was updated last month according to the time/date stamps ... why did it work for months.. then stop? ... and how would anyone know they had to go in and save settings just to generate these files that never existed before... and I know you say this has been there for over a year.. but.. this site has been operating for months without issue... so there was no indication.. and it's odd.. perhaps another bug.. ( please don't derail this by chasing this and not the key point ) .. but.. it tells me I'm up to date.. even though I'm one revision behind.. but I have to say.. that .1 revision has nothing to do with it obviously... the 'fix" or update.. did not apply to pre-existing users... .. those new files weren't created and it broke things.. that is my question... why? and that's where I suspect there is a bug.. in the update process...

By the way discourage our clients from using that plugin.. .. not because of you.. but because that api is pretty dated ..

Please Log in or Create an account to join the conversation.

  • Posts: 31
  • Thank you received: 1
8 years 6 months ago #239350

By the way.. I deeply appreciate your responses.. I am just one that is very thorough... since I did not write this myself, I need to know what the issue is because I have to report... ..... :) I typically write my own software, but I happen to love Hikashop

Please Log in or Create an account to join the conversation.

  • Posts: 31
  • Thank you received: 1
8 years 6 months ago #239387

Apparently they are still having the same issue .. trying to get more information.

In the mean time I've switched them to paypal standard and suggested they consider authorized.net instead.. every time I've tried to mess with paypal advanced it's always had problems. Paypal even considers it a legacy product.

I would still love to know what's going on however

Please Log in or Create an account to join the conversation.

  • Posts: 82867
  • Thank you received: 13373
  • MODERATOR
8 years 6 months ago #239390

Hi,

1.
For example, suppose that you had installed an old version which didn't had those files generated. And when you udpated, after you built the website, the plugins folder was not writable (it can happen when you migrate a website from one server to another, from dev to live environment, when you upload files/folders via FTP, etc). So the update still worked, but you didn't get the new files for the plugins including this plugin as it is not a critical issue for updates and old plugins will still work with new versions of HikaShop. Now, since the update you did with the previous release, you fixed the permissions in the plugins folder and thus the update process was able to update the files of the plugins, and you went for the version of more than a year ago of the paypal advanced plugin to the latest one, and thus you got the problem as you had to save the settings to have it generate the files.
I'm not saying that it was the reason for what you're describing. But it's a possibility.

2. Please try a transaction with the debug mode of the payment method activated. Then, look at the payment log in the HikaShop configuration. It should contain valuable information about what's going on.

Please Log in or Create an account to join the conversation.

Time to create page: 0.308 seconds
Powered by Kunena Forum