Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
reverse proxy issue? Fails on 15.1.5 works on 15.0.17
#1
I have create a simple app with 2 forms. each form has a button to go to the other form on async click
when run the first form appears but when I attempt to go to the 2nd form, I get an error. I asked the web IT what is causing the error and here is his response,
this program works under IW 15.0.17 but fails under 15.1.5.

below is response from customer IT staff.

So here’s what’s happening.  The site is making an ajax request that returns XML which has javascript commands that are being executed.  The one being returned is redirecting to a URL, but in that URL is the translation IP address.  I’m not sure if it’s possible with the program to tell it to use absolute URLs to the route (i.e. /webppreviewer_DEV/projecttestssl.dll/) without the domain or IP, or if there is a way around this.
 
The Url rewrite module on the reverse proxy is supposed to make this change, but it’s set to do it on outgoing html traffic.  I changed it to also look for outgoing XML and to add the <literal> tag, but it’s still not catching it, probably because it’s in a CDATA section.
[Image: 0?ui=2&ik=e38e4c2a0d&attid=0.1&permmsgid...8&disp=emb]
<response>
<execute>
<literal>
<![CDATA[
window.location.replace("http://10.10.250.38/webppreviewer_DEV/projecttestssl.dll/");
]]>
</literal>
</execute>
<trackid>11</trackid>
</response>
Reply
#2
IntraWeb is designed to work with Reverse Proxies but there is no need to rewrite anything. What software is that and what is being rewritten in the request?
Reply
#3
(11-13-2019, 09:20 AM)Alexandre Machado Wrote: IntraWeb is designed to work with Reverse Proxies but there is no need to rewrite anything. What software is that and what is being rewritten in the request?

I have sent the customer your request for more info and will post their response when I get it
The one thing that seems strange is that the test program works fine when build under 15.0.117 but fails when built using 15.1.5. 
We have several Intraweb apps running at this customers site all built on 15.0.17 any never had an issue like this.

Just heard back from customer. Here is their reponse

We are using the Url Rewrite module on IIS on Windows Server.  It looks for and rewrites the host name so that it will work correctly from the outside.  So the reverse proxy works like this –

From the outside a request is made to cdpservices.pcg.com which goes to our reverse proxy server in our DMZ.
The DMZ server takes the request and routes it to the internal CDPlus server.  Since the internal server is going to return either the internal name, or the translated IP it was accessed by from the DMZ server, we have to update those to cdpservices.pcg.com so that when another call, link, etc is made from the outside it gets routed to the right place.

If it doesn’t get re-written, then it’s passed through as it is now – http://10.10.250.30 to the outside and so the requests failed since it’s not a real IP from the outside.

Does that make sense?
Reply
#4
Yes, it explains why the issue happens. I'll just run some test before giving you a more complete response, but seems to me that rewriting the content is not the best way to do it.
Reply
#5
The only thing that the proxy should do is forwarding the request to the appropriate address without rewriting anything.

IntraWeb will generate relative paths only, unless it is necessary to generate absolute URLs. For instance, the mentioned response should actually be:

<response>
<execute>
<literal>
<![CDATA[
window.location.replace("/webppreviewer_DEV/projecttestssl.dll/");
]]>
</literal>
</execute>
<trackid>11</trackid>
</response>

which would work nicely.

URLRewrite as a reverse proxy is IMO far from ideal but it would also work if it just stop rewriting stuff on the fly.

The only thing you need to take care from your application is the URL base. I.e, if any path beyond the domain is required, you must set application URL base in your ServerController.

Example, if you need to type this in order to access your application:

http://cdpservices.pcg.com/webppreviewer_DEV/

Your URL base should be set to /webppreviewer_DEV/
Reply
#6
Hi, have you tested it without rewriting the URL?
Reply
#7
(11-19-2019, 08:55 AM)Alexandre Machado Wrote: Hi, have you tested it without rewriting the URL?
I have forwarded your response to the IT group at the customer site. Have to wait on their response.
I still am curious as to why it works in the older version of IW but not the new version.

Will post back once I hear back from the customer.

Bill B

One issue I just noticed is that I cannot set the URLBASE to /webppreviewer_dev/
when i exit the URLBASE field it changes it to /webppreviewerdev/

In fact if I try and set URLBASE to any value with underscore as a character it removes the underscore.

test_myapps becomes testmyapps
Reply
#8
Please install new 15.1.9: https://www.atozed.com/2019/11/15-1-9/

It should enable you to set the URLBase correctly.

Please let me know how it goes.

Cheers
Reply
#9
Are there any considerations when updating from 15.1.5?
Do I need to re-compile or re-install TMS IW components?

Bill B
Reply
#10
(11-20-2019, 04:29 PM)PDSBILL Wrote: Are there any considerations when updating from 15.1.5?
Do I need to re-compile or re-install TMS IW components?

Bill B

I updated to 15.1.9 and I can now set UrlBase, but the reverse proxy issue still exists with or without setting UrlBase
Like I said before, it works if I build under 15.0.17 but fails on 15.1.5 and 15.1.9
I am at a loss as to how to proceed.
Any help is very much appreciated
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)