cancel
Showing results for 
Search instead for 
Did you mean: 

Host header redirection issue

Highlighted
New Contributor

Host header redirection issue

Hi,

 

I'm configuring GLB services for an Hitachi HCP in a lab environment containing 2x HCPs and 2x vADCs (1 per site). The HCP services is accessed through a single end-point.

 

single end-point: hcp-glb.hcpdomain.com

HCP site 1 domain: hcp-pri.hcpdomain.com

HCP site 2 domain: hcp-rep.hcpdomain.com

 

Data access through HTTP 80, 443 works fine. However, i'm getting an issue when I try to login in the HCP search UI (HTTP 8888) through the single end-point: after entering the username and password in the search login page the browser returns to the login page.

 

When I use the HCP site 1 or site 2 end-point it works fine.

 

Session persistence (transparent session affinity) is set on HCP Pool for search HTTP port 8888.

 

The traffic script rule below is defined in the virtual server for the HTTP 8888 service:

 

$hostHeader = http.getHostHeader();

if ( string.containsI($hostHeader, "hcp-global.hcpdomain.com") )
{
   $newHostHeader = string.regexsub( $hostHeader, "hcp-glb.hcpdemo.com", "hcp-pri.hcpdemo.com" );
   http.setHeader( "Host", $newHostHeader );
   pool.use( "HCP_Search" );
}
else
{
   http.sendResponse( "403 Permission Denied",
          "text/html", "You Are Not Allowed Access To This Site.", "Set-Cookie: denied=Yes\r\nX-Foo: Bar" );
   pool.use( "discard" ) ;
}

 

Any thoughts?

 

Thanks in advance.