<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Relay response instantly times out with Direct Posting Method in Integration and Testing</title>
    <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Relay-response-instantly-times-out-with-Direct-Posting-Method/m-p/83717#M52796</link>
    <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;I've got a problem getting my &lt;STRONG&gt;sandbox&lt;/STRONG&gt;&amp;nbsp;merchant account to complete a transaction from our Java application.&lt;/P&gt;&lt;P&gt;Our app reads various user information, collects it into a form, and posts to the testing address at &lt;A href="https://test.authorize.net/gateway/transact.dll" target="_blank"&gt;https://test.authorize.net/gateway/transact.dll&lt;/A&gt;&amp;nbsp;, where the user sees a credit card payment page. With the correct API logins, SHA2 hash etc. these steps don't seem to be the problem.&lt;/P&gt;&lt;P&gt;The problem occurs the moment the user hits the submit button on the credit card payment form.&lt;/P&gt;&lt;P&gt;We tend to get 2 versions of the response, one saying:&lt;/P&gt;&lt;P&gt;"&lt;FONT face="courier new,courier"&gt;&lt;SPAN&gt;An error occurred while trying to report this transaction to the merchant. An e-mail has been sent to the merchant informing them of the error. The following is the result of the attempt to charge your credit card.&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;This transaction has been approved.&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;It is advisable for you to contact the merchant to verify that you will receive the product or service.&lt;/FONT&gt;"&lt;/P&gt;&lt;P&gt;While the other being more direct saying that our script timed out.&lt;/P&gt;&lt;P&gt;In the merchant email, the errors were all "timed out".&lt;/P&gt;&lt;P&gt;But to me the error occurred instantly. There was no time in between hitting the submit form button and the error message.&lt;/P&gt;&lt;P&gt;I have since looked around this forum for similar problems but none of them seem to be exactly like mine.&lt;/P&gt;&lt;P&gt;I have checked out the article about basic trouble shooting of relay responses at&amp;nbsp;&lt;A title="Relay Response Basic Trouble Shooting" href="https://community.developer.cybersource.com/t5/The-authorize-net-Developer-Blog/Relay-Response-Basics-and-Troubleshooting/ba-p/9536" target="_self"&gt;https://community.developer.cybersource.com/t5/The-authorize-net-Developer-Blog/Relay-Response-Basics-and-Troubleshooting/ba-p/9536&lt;/A&gt;&amp;nbsp;and can confirm:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;the x_relay_url is spelt correctly in the data we submitted to the "transact.dll" page;&lt;/LI&gt;&lt;LI&gt;The x_relay_url is exposed to the public internet. By default when a GET request hits it, it just displays the current time with a message saying that yes this path is exposed to the Authorize.net server. When a POST request comes in, it then attempts to get the request parameters and further process them.&amp;nbsp;&lt;/LI&gt;&lt;LI&gt;A special setup: in the testing, our product by default runs on http on port 9xxx. Users normally access it by putting in localhost:9xxx/(whatever path) to access different parts of it. I used the service of Ngrok to build an HTTP tunnel so there is a port forwarding arrangement between the port 80 of the Ngrok host somewhere on the AWS and the http port 9xxx of my localhost. The Ngrok's host name is publicly discoverable. A user can reach my localhost:9xxx by just putting in "http://{Ngrok host address}".&lt;/LI&gt;&lt;LI&gt;For Authorize.net postback, a servlet is listening on a path something like "/gateway/authorize-net". The full address of "http://{Ngrok Host}/gateway/authorize-net" is publicly accessible. By hitting the URL in the browser (GET), it shows the current time.&lt;/LI&gt;&lt;LI&gt;The tunnel is an HTTP to HTTP tunnel. The host on Ngrok in this situation is not running on port 443 therefore does not have certificate problems.&lt;/LI&gt;&lt;LI&gt;In the sandbox account's management UI, I have added this particular full address mentioned in step 4 as the &lt;STRONG&gt;default relay response URL&lt;/STRONG&gt;, under the &lt;STRONG&gt;Response/Receipt URLs&lt;/STRONG&gt; section.&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;I need to improve and test some features of our product for some customers using the Authorize.net services. As mentioned before, right now I'm using a sandbox account and posting the details to&amp;nbsp;&lt;A href="https://test.authorize.net/gateway/transact.dll" target="_blank"&gt;https://test.authorize.net/gateway/transact.dll&lt;/A&gt;, with x_relay_response: TRUE, x_relay_URL: filled in and publicly accessible.&lt;/P&gt;&lt;P&gt;Appreciate any help.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 10 Aug 2022 07:19:04 GMT</pubDate>
    <dc:creator>leomy</dc:creator>
    <dc:date>2022-08-10T07:19:04Z</dc:date>
    <item>
      <title>Relay response instantly times out with Direct Posting Method</title>
      <link>https://community.developer.cybersource.com/t5/Integration-and-Testing/Relay-response-instantly-times-out-with-Direct-Posting-Method/m-p/83717#M52796</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;I've got a problem getting my &lt;STRONG&gt;sandbox&lt;/STRONG&gt;&amp;nbsp;merchant account to complete a transaction from our Java application.&lt;/P&gt;&lt;P&gt;Our app reads various user information, collects it into a form, and posts to the testing address at &lt;A href="https://test.authorize.net/gateway/transact.dll" target="_blank"&gt;https://test.authorize.net/gateway/transact.dll&lt;/A&gt;&amp;nbsp;, where the user sees a credit card payment page. With the correct API logins, SHA2 hash etc. these steps don't seem to be the problem.&lt;/P&gt;&lt;P&gt;The problem occurs the moment the user hits the submit button on the credit card payment form.&lt;/P&gt;&lt;P&gt;We tend to get 2 versions of the response, one saying:&lt;/P&gt;&lt;P&gt;"&lt;FONT face="courier new,courier"&gt;&lt;SPAN&gt;An error occurred while trying to report this transaction to the merchant. An e-mail has been sent to the merchant informing them of the error. The following is the result of the attempt to charge your credit card.&lt;/SPAN&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;FONT face="courier new,courier"&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;This transaction has been approved.&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT face="courier new,courier"&gt;It is advisable for you to contact the merchant to verify that you will receive the product or service.&lt;/FONT&gt;"&lt;/P&gt;&lt;P&gt;While the other being more direct saying that our script timed out.&lt;/P&gt;&lt;P&gt;In the merchant email, the errors were all "timed out".&lt;/P&gt;&lt;P&gt;But to me the error occurred instantly. There was no time in between hitting the submit form button and the error message.&lt;/P&gt;&lt;P&gt;I have since looked around this forum for similar problems but none of them seem to be exactly like mine.&lt;/P&gt;&lt;P&gt;I have checked out the article about basic trouble shooting of relay responses at&amp;nbsp;&lt;A title="Relay Response Basic Trouble Shooting" href="https://community.developer.cybersource.com/t5/The-authorize-net-Developer-Blog/Relay-Response-Basics-and-Troubleshooting/ba-p/9536" target="_self"&gt;https://community.developer.cybersource.com/t5/The-authorize-net-Developer-Blog/Relay-Response-Basics-and-Troubleshooting/ba-p/9536&lt;/A&gt;&amp;nbsp;and can confirm:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;the x_relay_url is spelt correctly in the data we submitted to the "transact.dll" page;&lt;/LI&gt;&lt;LI&gt;The x_relay_url is exposed to the public internet. By default when a GET request hits it, it just displays the current time with a message saying that yes this path is exposed to the Authorize.net server. When a POST request comes in, it then attempts to get the request parameters and further process them.&amp;nbsp;&lt;/LI&gt;&lt;LI&gt;A special setup: in the testing, our product by default runs on http on port 9xxx. Users normally access it by putting in localhost:9xxx/(whatever path) to access different parts of it. I used the service of Ngrok to build an HTTP tunnel so there is a port forwarding arrangement between the port 80 of the Ngrok host somewhere on the AWS and the http port 9xxx of my localhost. The Ngrok's host name is publicly discoverable. A user can reach my localhost:9xxx by just putting in "http://{Ngrok host address}".&lt;/LI&gt;&lt;LI&gt;For Authorize.net postback, a servlet is listening on a path something like "/gateway/authorize-net". The full address of "http://{Ngrok Host}/gateway/authorize-net" is publicly accessible. By hitting the URL in the browser (GET), it shows the current time.&lt;/LI&gt;&lt;LI&gt;The tunnel is an HTTP to HTTP tunnel. The host on Ngrok in this situation is not running on port 443 therefore does not have certificate problems.&lt;/LI&gt;&lt;LI&gt;In the sandbox account's management UI, I have added this particular full address mentioned in step 4 as the &lt;STRONG&gt;default relay response URL&lt;/STRONG&gt;, under the &lt;STRONG&gt;Response/Receipt URLs&lt;/STRONG&gt; section.&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;I need to improve and test some features of our product for some customers using the Authorize.net services. As mentioned before, right now I'm using a sandbox account and posting the details to&amp;nbsp;&lt;A href="https://test.authorize.net/gateway/transact.dll" target="_blank"&gt;https://test.authorize.net/gateway/transact.dll&lt;/A&gt;, with x_relay_response: TRUE, x_relay_URL: filled in and publicly accessible.&lt;/P&gt;&lt;P&gt;Appreciate any help.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 10 Aug 2022 07:19:04 GMT</pubDate>
      <guid>https://community.developer.cybersource.com/t5/Integration-and-Testing/Relay-response-instantly-times-out-with-Direct-Posting-Method/m-p/83717#M52796</guid>
      <dc:creator>leomy</dc:creator>
      <dc:date>2022-08-10T07:19:04Z</dc:date>
    </item>
  </channel>
</rss>

