118Citrix NetScaler Policy Configuration and Reference Guide

Prefixes That Extract HTTP Headers

HTTP Header Prefix

Description

 

 

HTTP.RES.SET_COOKIE.

Returns the value of Path field of the cookie

COOKIE("name").PATHPATH.

as a slash- (“/”) separated list. Multiple

GET(n)

instances of a slash are treated as single slash.

or

If multiple Path fields are present, the value of

the first instance is returned.

HTTP.RES.SET_COOKIE2.

For example, the following is a cookie with

COOKIE("name").PATHPATH.

two path fields:

GET(n)

Set-Cookie : Customer = "ABC";

 

PATH="/a//b/c"; PATH= "/x/y/z"

 

The following expression returns /a//b/c from

 

this cookie:

 

http.res.set_cookie.

 

cookie("Customer").path

 

The following expression returns b:

 

http.res.set_cookie.

 

cookie("Customer").path.get(2)

 

Quotes are stripped from the returned value.

 

A string of zero length is returned if the Path

 

field or its value is absent.

 

 

HTTP.RES.SET_COOKIE.

Ignores the empty elements in the list. For

COOKIE("name").PATH.IGNORE_

example, in the list a=10,b=11, ,c=89, the

EMPTY_ELEMENTS

element delimiter in the list is , and the list has

or

an empty element following a=10. The

element following b=11 is not considered an

HTTP.RES.SET_COOKIE2.

empty element.

As another example, in the following

COOKIE("name").PATH.IGNORE_

EMPTY_ELEMENTS

expression, if a request contains Cust_Header

 

: 123,,24, ,15 the following expression returns

 

a value of 4:

 

http.req.header("Cust_Header").

 

typecast_list_t(',').ignore_

 

empty_elements.count

 

The following expression returns a value of 5:

 

http.req.header("Cust_Header").

 

typecast_list_t(',').count

Page 132
Image 132
Citrix Systems 9.2 Returns the value of Path field of the cookie, As a slash- / separated list. Multiple, Two path fields