Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

successPP.php fails to retrieve $_POST data but Paypal IPN returns HTTP code 200 #6

Open
crizztoffer opened this issue Oct 25, 2021 · 10 comments
Assignees
Labels
bug Something isn't working help wanted Extra attention is needed question Further information is requested

Comments

@crizztoffer
Copy link
Contributor

Line 11 in successPP.php always reports that there is no return post data from paypal after a transaction is processed, and thus throws a 405. This is in sandbox. The IPN tracker DOES report an HTTP code of 200. All the error files contain nothing, and they each have been written to during testing to confirm write access. Under current paypal methodology for IPN use, cURL was adjusted to:

`curl_setopt($ch, CURLOPT_HTTP_VERSION, CURL_HTTP_VERSION_1_1);
curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);
curl_setopt($ch, CURLOPT_CAINFO, DIR . "/cert/cacert.pem");
curl_setopt($ch, CURLOPT_URL, $uri);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $encoded_data);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, $this->follow_location);
curl_setopt($ch, CURLOPT_TIMEOUT, $this->timeout);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HEADER, true);

	curl_setopt($ch, CURLOPT_SSLVERSION, 6);`

Current PHP version is 8. Haven't been able to find a work around for showing success. I should also mention that setting usecurl to false still reports a 200, but throws a 405.

@thexkey
Copy link
Member

thexkey commented Oct 25, 2021

Sadly, I don't have a paypal to help with this issue, thought that the PayPal side would have worked.

@thexkey
Copy link
Member

thexkey commented Oct 25, 2021

Also, I have noticed you were using Sandbox. Have you enabled Sandbox mode in config.php?

@thexkey thexkey added bug Something isn't working question Further information is requested labels Oct 25, 2021
@crizztoffer
Copy link
Contributor Author

crizztoffer commented Oct 25, 2021 via email

@crizztoffer
Copy link
Contributor Author

crizztoffer commented Oct 25, 2021 via email

@thexkey
Copy link
Member

thexkey commented Oct 25, 2021

I haven't quite figured this one out yet, but when I do I will share it.

Yeah, the paypal code is very old, it suprised me when it did sorta worked for you.

@crizztoffer
Copy link
Contributor Author

crizztoffer commented Oct 25, 2021 via email

@thexkey thexkey pinned this issue Oct 27, 2021
@thexkey
Copy link
Member

thexkey commented Oct 27, 2021

Just remembered something: successPP relies on phplistener.php aka https://github.com/Quixotix/PHP-PayPal-IPN and that is for PHP 5, however i do not know if this affects anything when using PHP 8.

@thexkey
Copy link
Member

thexkey commented Oct 27, 2021

i created a branch called LibraryPatch, commit 79534ff should have a fixed version of phplistener.php, but i dont know if it really works.

@thexkey
Copy link
Member

thexkey commented Nov 19, 2021

any progress on this issue?

@thexkey thexkey added the help wanted Extra attention is needed label Jan 3, 2022
@thexkey thexkey changed the title successPP.php fails to retrieve $_POST data but IPN returns HTTP code 200 successPP.php fails to retrieve $_POST data but Paypal IPN returns HTTP code 200 Jan 26, 2022
@thexkey
Copy link
Member

thexkey commented Sep 15, 2022

i am working on this issue again, currently re-writing most of the entire web code to fix most of this mess and allow plugins

@thexkey thexkey self-assigned this Sep 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants