PayPal Checkout fails after upgrade

For general questions and discussions specific to the AbleCommerce GOLD ASP.Net shopping cart software.
Post Reply
corgalore
Lieutenant, Jr. Grade (LT JG)
Lieutenant, Jr. Grade (LT JG)
Posts: 32
Joined: Thu Nov 08, 2012 2:57 pm

PayPal Checkout fails after upgrade

Post by corgalore » Fri Apr 07, 2017 4:15 am

We recently upgraded a customer site to AbleCommerce GoldR12SR1 (build 9266), but now the Express Checkout fails with this error:

2017-04-07 10:26:47,639 ERROR AbleCommerce An error has occured at https://www.timneytriggers.com/shop/Pay ... Action=SET
System.Web.HttpUnhandledException (0x80004005): Exception of type 'System.Web.HttpUnhandledException' was thrown. ---> PayPal.Exception.ConnectionException: Invalid HTTP response The underlying connection was closed: An unexpected error occurred on a receive.
at PayPal.HttpConnection.Execute(String payLoad, HttpWebRequest httpRequest)
at PayPal.APIService.MakeRequestUsing(IAPICallPreHandler apiCallHandler)
at PayPal.BasePayPalService.Call(IAPICallPreHandler apiCallHandler)
at PayPal.PayPalAPIInterfaceService.PayPalAPIInterfaceServiceService.SetExpressCheckout(SetExpressCheckoutReq setExpressCheckoutReq, String apiUserName)
at CommerceBuilder.Payments.Providers.PayPal.PayPalProvider.SetExpressCheckout(Boolean isPayPalCreditRequest)
at AbleCommerce.PayPalExpressCheckout.SetExpressCheckout(Boolean isBmlRequest)
at AbleCommerce.PayPalExpressCheckout.Page_Load(Object sender, EventArgs e)
at System.EventHandler.Invoke(Object sender, EventArgs e)
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.HandleError(Exception e)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest()
at System.Web.UI.Page.ProcessRequest(HttpContext context)
at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

The original site had .net framework targeting 4.0, which I changed to 4.5 during the upgrade. I then switched it back to 4.0 when I saw this was broken. I also tried adding this to the Global.asax:

Also, the upgrade wiped out much of the settings, so we had to re-enter credentials for gateways and such.

Code: Select all

System.Net.ServicePointManager.SecurityProtocol = (System.Net.SecurityProtocolType)3072;
What can we do? Is there any way to temporarily de-activate a payment method. That's so annoying that my only choice is to remove it completely.

EDIT: At first we were using this endpoint -> https://www.paypal.com/cgi-bin/webscr, then I switched to -> https://api-3t.paypal.com/nvp -- Same error on either endpoint.

Thanks in advance!

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: PayPal Checkout fails after upgrade

Post by Katie » Fri Apr 07, 2017 5:02 am

Hello,

If you are losing your gateway settings, then take a look at this page:

http://help.ablecommerce.com/index.htm# ... ld_r11.htm
Step 7)
IMPORTANT INFORMATION REGARDING NEW ENCRYPTION

This talks about setting a machine key in the web.config file which you'll need to do right away. Every time the application recycles, the gateway settings can be lost. It's an issue that we've been unable to figure out because it is specific to a very few servers.

You won't be able to easily remove the Express payment method, but all the other ones that you wish to hide can be changed without removing. Just select one of the admin groups and it will be hidden from your customers.

The Express error is another issue. Paypal is not requiring the newer SSL protocol TLS 1.2 yet, so this appears to be something different. Did you move the installation to a different server? What version did you upgrade from?

Katie
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

corgalore
Lieutenant, Jr. Grade (LT JG)
Lieutenant, Jr. Grade (LT JG)
Posts: 32
Joined: Thu Nov 08, 2012 2:57 pm

Re: PayPal Checkout fails after upgrade

Post by corgalore » Fri Apr 07, 2017 5:07 am

Katie,

The site stayed on the same server, with the same entry in IIS.

Here's the versioninfo.xml contents from the old site:

<VersionInfo>
<ReleaseLabel>GoldR7</ReleaseLabel>
<MajorVersion>7</MajorVersion>
<MinorVersion>0</MinorVersion>
<BuildNumber>87</BuildNumber>
<Revision>7118</Revision>
</VersionInfo>


The old PayPal assembly is version 7.87.5184.26315.

The new one is 7.92.6081.35358.

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: PayPal Checkout fails after upgrade

Post by Katie » Fri Apr 07, 2017 5:43 am

Have you checked the gateway settings and made sure they are still entered? Also, you should change the endpoint back to the one that is supposed to be used. Lastly, make sure you are using the latest version of the web.config. When PayPal was upgraded in Gold R9, there were specific changes that needed to be made to the web.config.

See http://help.ablecommerce.com/index.htm# ... _to_r9.htm

When doing multi-step upgrades, you still need to review the post-upgrade steps for each incremental upgrade.

Let me know if this solves the issue.
Katie
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

corgalore
Lieutenant, Jr. Grade (LT JG)
Lieutenant, Jr. Grade (LT JG)
Posts: 32
Joined: Thu Nov 08, 2012 2:57 pm

Re: PayPal Checkout fails after upgrade

Post by corgalore » Fri Apr 07, 2017 5:59 am

Katie,

I changed the endpoint back to: https://www.paypal.com/cgi-bin/webscr

I also reviewed that wiki entry. The latest version of the web.config that ships in the install package has removed the PayPal config section completely:

<section name="paypal" type="com.paypal.sdk.core.ConfigSectionHandler, paypal_base"/> <-- It's gone now

My web.config matches the latest version for R12SR1, except that I switched the target framework back to 4.0 when we had this PayPal error. Does this version require 4.5 ?

EDIT: Just confirmed 4.5 is required, probably because it kicks in the TLS or something. Authorize.net transactions were failing under .Net 4.0


Not sure where to go from here. Any logs I can check? PayPal is not outputting a log, despite having debug on. I only see app.log, audit_* and Auth.Net

User avatar
Katie
AbleCommerce Admin
AbleCommerce Admin
Posts: 2651
Joined: Tue Dec 02, 2003 1:54 am
Contact:

Re: PayPal Checkout fails after upgrade

Post by Katie » Mon Apr 10, 2017 9:20 am

After the changes you made, is the error message the same? If the server cannot make a connection to Paypal, then the error will be in the app.log file.

You can try adding <section name="paypal" type="com.paypal.sdk.core.ConfigSectionHandler, paypal_base"/> back in and see if that changes the error message.
Thank you for choosing AbleCommerce!

http://help.ablecommerce.com - product support
http://wiki.ablecommerce.com - developer support

Post Reply