246 Citrix NetScaler Policy Configuration and Reference Guide

add rewrite action act_external_to_internal REPLACE 'http.req.hostname.server' '"host_name_of_internal_Web_server"'

To create the rewrite policy, at the NetScaler command prompt, type:

add rewrite policy pol_external_to_internal 'http.req.hostname.server.eq("host_name_of_external_Web_server ")' act_external_to_internal

Bind the policy globally.

To redirect an external URL to an internal URL by using the configuration utility

1.In the navigation pane, expand Rewrite, and then click Actions.

2.In the details pane, click Add.

3.In the Create Rewrite Action dialog box, enter the name act_external_to_internal.

4.To replace the HTTP server hostname with the internal server name, choose Replace from the Type list box.

5.In the Header Name field, type Host.

6.In the String expression for replacement text field, type the internal hostname of your Web server.

7.Click Create and then click Close.

8.In the navigation pane, click Policies.

9.In the details pane, click Add.

10.In the Name field, type pol_external_to_internal. This policy will detect connections to the Web server.

11.In the Action drop-down menu, choose the action act_external_to_internal.

12.In the Expression editor, construct the following expression:

HTTP.REQ.HOSTNAME.SERVER.EQ("www.example.com")

13.Bind your new policy globally.

Page 260
Image 260
Citrix Systems 9.2 manual Bind the policy globally