PayPal IPN Failed Handshake Fix
Camasoft opened this issue · comments
I recently received a notification that PayPal IPN notifications sent to my website PayPal listener were failing. I was able to determine that all of the data was successfully received and stored in the database table, along with the VERIFIED response from PayPal, but they were receiving a 302 instead of a 200 response from my website. This turned out to be a needed fix in the return from the InstantPaymentNotificationsController::process
method:
Specifically line 50: return $this->redirect('/');
. This needs to be changed to
return CURLOPT_HTTP200ALIASES;
I am opening this issue and supplying the resolution in the hopes that anyone else who is still using CakePHP 2 and this plugin will find it helpful, since it appears this plugin has not been updated for a long time.
Thank you very much for your contribution. I would encourage you to fork and issue a pull request so that I may review it and get it checked in.
This fix worked for me. Thanks so much!