Using proxy servers with Visualization Platform client
When setting up a proxy server with Visualization Platform client, there are steps you must take if your internal application server port is protected by a firewall. In this situation, when the proxy server changes the URL to point to the new context’s port, that port is unavailable due to the firewall. The usual solution is to configure a reverse proxy, but if you are using multiple proxies and a reverse proxy is not practical for your installation, Visualization Platform client can perform the redirection.
To redirect a page without using a reverse proxy, Visualization Platform client forwards the URL to redirect to the processRedirect.jsp page and updates the browser’s location bar accordingly. This action processes on the client. The browser takes the current URL location and updates the rest of the URI using the redirected URL. You must also set the ENABLE_CLIENT_SIDE_REDIRECT configuration parameter in the <context root>/WEB‑INF/web.xml file to True and modify the redirect attributes in the <context root>/WEB‑INF/struts‑config.xml file. The necessary modifications are included as comments in the file. You just need to comment out the lines that have the redirect attribute set to True and uncomment the lines that forward to the processRedirect.jsp page.
For example, the following code is the struts-config.xml entry for the login action:
<!-- Process a user login -->
<action
path="/login"
name="loginForm"
scope="request"
input="/iportal/activePortal/private/login.jsp"
type="com.actuate.activeportal.actions.AcSsoLoginAction"
validate="false">
<forward name="loginform" path="/iportal/activePortal/private/login.jsp"/>
<!-- <forward name="success" path="/iportal/activePortal/private/common/processredirect.jsp?redirectPath=/getfolderitems.do" />
-->
<forward name="success" path="/dashboard/jsp/myfiles.jsp" redirect="true"/>
<forward name="dashboard" path="/dashboard" redirect="true"/>
<forward name="ajcLogin" path="/ajclanding.jsp" redirect="true"/>
<forward name="landing" path="/landing.jsp" redirect="false"/>
<forward name="activate" path="/activate.jsp" redirect="false" />
<forward name="wait" path="/checksaml.jsp" redirect="false" />
</action>
By default the forward statement for success points to myfiles.jsp with the redirect attribute set to True. This code instructs the application server to send a redirect with the myfiles.jsp URL when the user logs in.
From behind a firewall and proxy, this redirect method fails because the redirect sent by the application server points to the application server port instead of the firewall and proxy port. For success, comment out the line having redirect="true". Uncomment the line that points to processRedirect.jsp. The following code shows the updated entry in struts‑config.xml:
<!-- Process a user login -->
<action
path="/login"
name="loginForm"
scope="request"
input="/iportal/activePortal/private/login.jsp"
type="com.actuate.activeportal.actions.AcSsoLoginAction"
validate="false">
<forward name="loginform" path="/iportal/activePortal/private/login.jsp"/>
<forward name="success" path="/iportal/activePortal/private/common/processredirect.jsp?redirectPath=/getfolderitems.do" />
<!-- <forward name="success" path="/dashboard/jsp/myfiles.jsp" redirect="true"/>-->
<forward name="dashboard" path="/dashboard" redirect="true"/>
<forward name="ajcLogin" path="/ajclanding.jsp" redirect="true"/>
<forward name="landing" path="/landing.jsp" redirect="false"/>
<forward name="activate" path="/activate.jsp" redirect="false" />
<forward name="wait" path="/checksaml.jsp" redirect="false" />
</action>
This change needs to be made for all the actions in struts-config.xml that send a redirect to the browser.