Could not establish trust relationship...

Hi Wyatt,

I can never get keys generated. PayPal seems to behave correctly. My paychecker is called, but keys are never sent to the buyer. I added a bunch of trace statements and see that in every instance I get a "Could not establish trust relationship" error. Do you recognize this error? Can you help me get rid of it?

Thanks,Mark

__________________________01/05/2012 09:11:57Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->GeneratePKeys-> called__________________________01/05/2012 09:11:57Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->GeneratePKeys-> calling return PostRequest(postData);__________________________01/05/2012 09:11:57Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> APIKey = 303600904ebd23345af782.99746993__________________________01/05/2012 09:11:57Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> post_url = https://wyday.com/limelm/api/rest/__________________________01/05/2012 09:11:57Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> post_string = method=limelm.pkey.generate&version_id=417&num_keys=1&num_acts=1&email=mark%40fowler-family.net&api_key=303600904ebd23345af782.99746993__________________________01/05/2012 09:11:57Error in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - PaymentSettings->SendPKeys-> catch (failed to generate product keys) Exception:The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel.__________________________

Hi Wyatt,

Thanks for your reply.

This is my first web site and there are some fundamental things I do not understand. Will you please answer a few basic questions just to get me started?

My entire site is currently non-secure. --- Do I -have- to use a secure site (or page or whatever) for part - or all - of the sale transaction? Paypal does not seem to have a problem calling my page (paychecker) on my non-secure site (using http). --- Since the part that is failing is the call to generate the key, is the problem that I am calling from a non-secure page (paychecker) to Lime's secure page? Can I just make that call non-securely using http instead of https?

If I have to use a secure page/site, do I need to buy a security certificate or can I use the provider's generic one?

When I go to the setup SSL page at my site provider (earthlink) they offer me the following advise: - Ensure all secure files are placed in the /secure and /secure-cgi-bin directories. - Your secure URL is: https://secure38.securewebsession.com/fwlr.com

--- Do I have to put pay-checker.aspx in that folder? What is that secure URL all about?

Thanks for any help you can give me on this.Mark

--- Do I -have- to use a secure site (or page or whatever) for part - or all - of the sale transaction? Paypal does not seem to have a problem calling my page (paychecker) on my non-secure site (using http).

If you're not processing the credit cards on your website then you don't need an SSL certificate. So, if you're just using PayPal and/or Moneybookers then you don't need a secure site.

--- Since the part that is failing is the call to generate the key, is the problem that I am calling from a non-secure page (paychecker) to Lime's secure page? Can I just make that call non-securely using http instead of https?

Yes, just open the LimeLM.cs file (or if you're using VB.NET open the LimeLM.vb file) and change the the "post_url" constant to be "http://wyday.com/limelm/api/rest/" and not "https://wyday.com/limelm/api/rest/".

However, the exception you were getting is really a server configuration error. But changing the contact URL from https to http is a quick fix.

When I go to the setup SSL page at my site provider (earthlink) they offer me the following advise:- Ensure all secure files are placed in the /secure and /secure-cgi-bin directories.- Your secure URL is: https://secure38.securewebsession.com/fwlr.com

--- Do I have to put pay-checker.aspx in that folder? What is that secure URL all about?

Paychecker doesn't need to be secure because it weeds out bad requests and it doesn't accept user information.

Hi Wyatt,

Changing the post url from https to http seemed to work, but now I am getting a whole bunch of activations on each purchase!

For example, on 1/6/2012, I tested a purchase on my machine at 07:18 amPayPal shows a sale at 06:17:59 PST with the correct parametersLimeLM shows a key issued at 9:18 am: 6MBA-82QX-ISK8-T5F8-VEC9-4S6N-2ATAMy website log shows a key returned from LimeLM.GeneratePKeys matching the 9:18 key shown at LimeLM.I am pretty sure the times are all correct given different time zones.

This is for sure the only transaction I executed this morning, but there are 8 other keys issued over the next two minutes according to the LimeLM interface that are not shown on PayPal or in my web log.

Another example: Earlier this morning, I log key VKWT-3Q5B-TFS4-BN5V-TQ86-S9G3-INTA, but there is another key at about the same time not logged.

If you have an idea about the problem, please let me know, otherwise, will you please reset my keys issued back to zero so i can continue testing to try to figure this out?

Thanks,Mark

Aaarggh! Another key issued at 10:44! I did nothing to cause this (as far as I can tell 🙂. I was not even at my computer. There is nothing new in my web log!

OK - I was wrong: they are being logged, but I am taking no action to make them happen. Is Paypal calling my paychecker page over and over again? Does the paypal=1 in the URL indicate that? (i.e. http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1)

Here are the logs for the last three that i did not (intentionally) cause:

__________________________01/06/2012 09:49:38Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->Page_Load__________________________01/06/2012 09:49:38Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->ValidatePP__________________________01/06/2012 09:49:39Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->Page_Load-> returns True__________________________01/06/2012 09:49:39Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->Page_Load-> calls PaymentSettings.SendPKeys(1, mark@fowler-family.net, Mark, Fowler);__________________________01/06/2012 09:49:39Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - PaymentSettings->SendPKeys-> calls resp = LimeLM.GeneratePKeys(417, 1, 1, mark@fowler-family.net, , );__________________________01/06/2012 09:49:39Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->GeneratePKeys-> called__________________________01/06/2012 09:49:39Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->GeneratePKeys-> calling return PostRequest(postData);__________________________01/06/2012 09:49:39Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> APIKey = 303600904ebd23345af782.99746993__________________________01/06/2012 09:49:39Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> post_url = http://wyday.com/limelm/api/rest/__________________________01/06/2012 09:49:39Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> post_string = method=limelm.pkey.generate&version_id=417&num_keys=1&num_acts=1&email=mark%40fowler-family.net&api_key=303600904ebd23345af782.99746993__________________________01/06/2012 09:49:39Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> post_response = <?xml version="1.0" encoding="utf-8"?><rsp stat="ok"><pkeys total="1"><pkey id="79152" key="Y8BW-3EMT-IZIE-SSA4-FFAF-W7DI-C6TA"/></pkeys></rsp>

__________________________01/06/2012 09:49:39Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - PaymentSettings->SendPKeys-> LimeLM.GeneratePKeys returns <?xml version="1.0" encoding="utf-8"?><rsp stat="ok"><pkeys total="1"><pkey id="79152" key="Y8BW-3EMT-IZIE-SSA4-FFAF-W7DI-C6TA"/></pkeys></rsp>

__________________________01/06/2012 10:32:27Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->Page_Load__________________________01/06/2012 10:32:27Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->ValidatePP__________________________01/06/2012 10:32:28Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->Page_Load-> returns True__________________________01/06/2012 10:32:28Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->Page_Load-> calls PaymentSettings.SendPKeys(1, mark@fowler-family.net, Mark, Fowler);__________________________01/06/2012 10:32:28Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - PaymentSettings->SendPKeys-> calls resp = LimeLM.GeneratePKeys(417, 1, 1, mark@fowler-family.net, , );__________________________01/06/2012 10:32:28Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->GeneratePKeys-> called__________________________01/06/2012 10:32:28Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->GeneratePKeys-> calling return PostRequest(postData);__________________________01/06/2012 10:32:28Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> APIKey = 303600904ebd23345af782.99746993__________________________01/06/2012 10:32:28Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> post_url = http://wyday.com/limelm/api/rest/__________________________01/06/2012 10:32:28Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> post_string = method=limelm.pkey.generate&version_id=417&num_keys=1&num_acts=1&email=mark%40fowler-family.net&api_key=303600904ebd23345af782.99746993__________________________01/06/2012 10:32:29Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> post_response = <?xml version="1.0" encoding="utf-8"?><rsp stat="ok"><pkeys total="1"><pkey id="79154" key="6J4V-DJEI-S7ZK-T5TJ-X926-8S59-5WTA"/></pkeys></rsp>

__________________________01/06/2012 10:32:29Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - PaymentSettings->SendPKeys-> LimeLM.GeneratePKeys returns <?xml version="1.0" encoding="utf-8"?><rsp stat="ok"><pkeys total="1"><pkey id="79154" key="6J4V-DJEI-S7ZK-T5TJ-X926-8S59-5WTA"/></pkeys></rsp>

__________________________01/06/2012 11:57:55Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->Page_Load__________________________01/06/2012 11:57:55Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->ValidatePP__________________________01/06/2012 11:57:56Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->Page_Load-> returns True__________________________01/06/2012 11:57:56Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - paychecker->Page_Load-> calls PaymentSettings.SendPKeys(1, mark@fowler-family.net, Mark, Fowler);__________________________01/06/2012 11:57:56Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - PaymentSettings->SendPKeys-> calls resp = LimeLM.GeneratePKeys(417, 1, 1, mark@fowler-family.net, , );__________________________01/06/2012 11:57:56Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->GeneratePKeys-> called__________________________01/06/2012 11:57:56Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->GeneratePKeys-> calling return PostRequest(postData);__________________________01/06/2012 11:57:56Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> APIKey = 303600904ebd23345af782.99746993__________________________01/06/2012 11:57:56Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> post_url = http://wyday.com/limelm/api/rest/__________________________01/06/2012 11:57:56Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> post_string = method=limelm.pkey.generate&version_id=417&num_keys=1&num_acts=1&email=mark%40fowler-family.net&api_key=303600904ebd23345af782.99746993__________________________01/06/2012 11:57:57Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - LimeLM->PostRequest-> post_response = <?xml version="1.0" encoding="utf-8"?><rsp stat="ok"><pkeys total="1"><pkey id="79159" key="94W9-C6YN-AGN2-UIIG-G3WT-2J9C-RATA"/></pkeys></rsp>

__________________________01/06/2012 11:57:57Log in: http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1 - PaymentSettings->SendPKeys-> LimeLM.GeneratePKeys returns <?xml version="1.0" encoding="utf-8"?><rsp stat="ok"><pkeys total="1"><pkey id="79159" key="94W9-C6YN-AGN2-UIIG-G3WT-2J9C-RATA"/></pkeys></rsp>

Are you making multiple orders? That's what sounds like is happening. Perhaps they're being cached from multiple days back when your server wasn't correctly verifying orders.

Try canceling all orders in your PayPal sandbox account. Then make a single order.

Hi Wyatt,

Thanks for your help on this issue. I think you are right about PayPal reprocessing failed attempts. They have stopped and I received the following email from PayPal (quite belatedly, it seems to me) confirming (sort-of) what you were saying.

Per all the extra license keys generated, if I just delete them does it reset the count back to zero on my plan?

Thanks,Mark

------------------------------------------- from PayPal --------------------------------------------------------Hello Mark,

Please check your server that handles PayPal Instant Payment Notifications (IPN). IPNs sent to the following URL(s) are failing:

http://dftools.fwlr.com/Buy-Paychecker.aspx?paypal=1

If you do not recognize this URL, you may be using a service provider that is using IPN on your behalf. Please contact your service provider with the above information. If this problem continues, IPNs may be disabled for your account.

Thank you for your prompt attention to this issue.

Thanks,PayPal----------------------------------------------- end ------------------------------------------------------------