0

Maybe anyone can help solve this issue. Everything worked fine ages, and yesterday, PayPal post back failed. It stopped updating any statuses.

Log is showing

[postback_to] => https://www.paypal.com/cgi-bin/webscr
[postback] => mc_gross=1.00&invoice=100002123&auth_exp=08%3A29%3A30+Oct+19%2C+2014+PDT&protection_eligibility=Ineligible&address_status=unconfirmed&item_number1=test&payer_id=8EUEYETHYRST8&tax=0.17&address_street=%D1%84%D1%8B%D0%B2%D1%84%D1%8B%D0%B2%D1%84%D1%8B%D0%B2&payment_date=08%3A29%3A30+Sep+19%2C+2014+PDT&payment_status=Pending&charset=UTF-8&address_zip=dsfsdf&mc_shipping=0.00&mc_handling=0.00&first_name=Sergey&transaction_entity=auth&address_country_code=LV&address_name=%D1%8B%D0%B2%D1%84%D1%8B%D0%B2+%D0%B2%D1%84%D1%8B%D0%B2&notify_version=3.8&custom=&payer_status=verified&business=Info%40eurofishshop.com&address_country=Latvia&num_cart_items=1&mc_handling1=0.00&address_city=%D1%84%D1%8B%D0%B2%D1%84%D1%8B%D0%B2&verify_sign=ALBe4QrXe2sJhpq1rIN8JxSbK4RZAc6KHII6HCE8Yo15IkQfFCf9w2Yp&payer_email=ianjanho%40gmail.com&mc_shipping1=0.00&parent_txn_id=&txn_id=1WA86899Y17300749&payment_type=instant&remaining_settle=10&auth_id=1WA86899Y17300749&last_name=Yakovel&address_state=J%C4%93kabpils&item_name1=test&receiver_email=Info%40eurofishshop.com&auth_amount=1.00&quantity1=1&receiver_id=BU6HTDF6LYK4L&pending_reason=authorization&txn_type=cart&mc_gross_1=0.83&mc_currency=EUR&residence_country=LV&transaction_subject=&payment_gross=&auth_status=Pending&ipn_track_id=b4311d9ee7e6&cmd=_notify-validate
[postback_result] => HTTP/1.1 403 Forbidden
Server: AkamaiGHost
Mime-Version: 1.0
Content-Type: text/html
Content-Length: 285
Expires: Fri, 19 Sep 2014 15:30:16 GMT
Date: Fri, 19 Sep 2014 15:30:16 GMT
Connection: close
Strict-Transport-Security: max-age=63072000

<HTML><HEAD>
<TITLE>Access Denied</TITLE>
</HEAD><BODY>
<H1>Access Denied</H1>

You don't have permission to access "http&#58;&#47;&#47;www&#46;paypal&#46;com&#47;cgi&#45;bin&#47;webscr" on this server.<P>
Reference&#32;&#35;18&#46;df9b7b5c&#46;1411140616&#46;418048a
</BODY>
</HTML>

    [exception] => PayPal IPN postback failure. See paypal_unknown_ipn.log for details.
    [__pid] => 26563
1

1 Answer 1

1

I had the same situation and the link that Sergey posted did help me. Let me share my solution.

The fix should be applied to the app/code/core/Mage/Paypal/Model/Ipn.php file (copy it to local of course).

Find the protected function _postBack(Zend_Http_Client_Adapter_Interface $httpAdapter) and change the line


$httpAdapter->write(Zend_Http_Client::POST, $this->_config->getPaypalUrl(), '1.1', array(), $sReq);

with the following:


$httpAdapter->write(Zend_Http_Client::POST, $this->_config->getPaypalUrl(), '1.1', array('Connection: Close', 'User-Agent: something-here'), $sReq);
3
  • you should try to override Core files rather than copying them locally. Oct 8, 2014 at 14:00
  • In the 1.9.0.1 Core Code there is the "Connection: Close" included in the parameters. So it will be enough to add this to the Parameter.
    – tomtone
    Dec 18, 2014 at 13:30
  • Is this still a bug in Magento? If so then plz log it at Magento LTS github.com/OpenMage/magento-lts/issues
    – snh_nl
    Nov 2, 2020 at 12:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.