Citrix ADC

Insert the IP address of the client in the request header

A Citrix ADC uses the subnet IP (SNIP) address to connect to the server. The server need not be aware of the client.

However, in some situations, the server needs to be aware of the client it has to serve. When you enable the client IP setting, the appliance inserts the client’s IPv4 or IPv6 address while forwarding the requests to the server. The server inserts this client IP in the header of the responses. The server is thus aware of the client.

Note: To insert multiple headers, you need to perform one of the following:

  • Add rewrite policies to check CLIENT.IS_SSL and insert appropriate header.
  • Bind the appropriate rewrite policy for each virtual server based on the type.

To insert the client IP address in the client request by using the CLI

At the command prompt, type:

set service  -CIP   

Example:

set service Service-HTTP-1 -CIP enabled X-Forwarded-For 

To insert the client IP address in the client request by using the GUI

  1. Navigate toTraffic Management>Load Balancing>Services, and edit a service.
  2. In theService Settingspane, click theedit icon.
  3. In theLoad Balancing Servicepane, select theInsert Client IP Addresscheck box.
Insert the IP address of the client in the request header