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
#21
It can't be correct if it is rewriting stuff on the fly. IW doesn't need that. IP being written is a direct consequence of rewriting stuff that shouldn't be rewritten
Reply
#22
Why are you using "MyApp/" and "Proxy/" as URL base on your web.config file???

The document I published is a *general guide* a *how to*. The names of my sample applications and the IP addresses I used are *examples*. It doesn't apply as is to your application. If you just copied it of course it won't work!
Reply
#23
(02-05-2020, 10:34 AM)Alexandre Machado Wrote: Why are you using "MyApp/" and "Proxy/" as URL base on your web.config file???

The document I published is a *general guide* a *how to*. The names of my sample applications and the IP addresses I used are *examples*. It doesn't apply as is to your application. If you just copied it of course it won't work!

Our customer setup a test domain and I asked them to follow the instructions replacing the App name and IP address of the proxy as required.
My program does work with this setup if I use  OnClick to go to another form but not if I use onAsyncClick. I set the rewrite rule in the serverController onConfig to MyApp to match the name in the rewrite rule.

This is what we have in our new test setup on the proxy server. The 

   <rule name="Rewrite rule for ISAPI Intraweb application" stopProcessing="true">
              <match url="^MyApp/(.*)" />
              <action type="Rewrite" url="http://10.10.250.38/webppreviewer_test/ppwebreviewer.dll/{R:1}" logRewrittenUrl="true" />
            </rule>

The url I am going to is https://cdp.palmcoastgov.com/myapp/
The destination url is v-PercontiSrv01.ci.palm-coast.fl.us/webppreviewer_test/ppwebreviewer.dll

is this what the rewrite rule should look like? if not can you tell us how it should look.

  <rule name="Rewrite rule for ISAPI Intraweb application" stopProcessing="true">

              <match url="^MyApp/(.*)" />
              <action type="Rewrite" url="http://v-PercontiSrv01.ci.palm-coast.fl.us/ppwebreviewer.dll/{R:1}" logRewrittenUrl="true" />
            </rule>

Bill B

Reply
#24
What's the host name returned by server with IP 10.10.250.38 ?

This is the key. Please add this server variable to your inbound rule:


[Image: HTTP_HOST.png]
Reply
#25
I'll add something to the redirection layer which will avoid this and you don't need to add a server host variable in the rewritten request. Hold on and I'll have a build for you to test, compatible with 15.1.12
Reply
#26
OK, We have it fixed. We changed the rewrite rule from IP address to domain url point to destination and added the destination to the proxy servers HOST file

I cannot update to 15.1.12 or higher as our license ended with 15.1.9.

Thank you again for your help. I took awhile but worth it.

Bill B
Reply
#27
Hum... We just released a new update IW 15.1.13 which will probably work on our scenario without any of those changes (except for the URL rewrite rule itself).

Thanks for the feedback
Reply
#28
You may want to update you document on reverse proxy for users not able to update to 15.1.13 (like me) with details on using a Server Variable to replace IP Address.
also fix the missing single quote
procedure TIWServerController.IWServerControllerBaseConfig(Sender: TObject);
begin
Self.RewriteURL := '/MyApp; // this must match the URL Rewrite rule
end;
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)