Product Documentation

policyevaluation

Sep 07, 2016

Configuration for expr evaluation resource.

Properties (click to see Operations)

Name Data Type Permissions Description
expression
<String>
Read-write
Expression string. For example: http.req.body(100).contains("this").
action
<String>
Read-write
Rewrite action name. Supported rewrite action types are:
-delete
-delete_all
-delete_http_header
-insert_after
-insert_after_all
-insert_before
-insert_before_all
-insert_http_header
-replace
-replace_all
.
Minimum length = 1
type
<String>
Read-write
Indicates request or response input packet.
Possible values = HTTP_REQ, HTTP_RES, TEXT
input
<String>
Read-write
Text representation of input packet.
pitmodifiedinputdata
<String>
Read-only
Text representation of packet after evaluating expression or rewrite action.
pitboolresult
<Boolean>
Read-only
Result of the expression in bool format.
pitnumresult
<Double>
Read-only
Result of the expression in num format.
pitdoubleresult
<Double>
Read-only
Result of the expression in double format.
pitulongresult
<Double>
Read-only
Result of the expression in unsigned long format.
pitrefresult
<String>
Read-only
Result of the expression in string format.
pitoffsetresult
<Double>
Read-only
Offset of the resultant sting.
pitoffsetresultlen
<Double>
Read-only
Offset length of the resultant sting.
istruncatedrefresult
<Boolean>
Read-only
Identify whether ref result is truncated result.
pitboolevaltime
<Double>
Read-only
Average evaluation time of bool type expression in nanoseconds.
pitnumevaltime
<Double>
Read-only
Average evaluation time of num type expression in nanoseconds.
pitdoubleevaltime
<Double>
Read-only
Average evaluation time of double type expression in nanoseconds.
pitulongevaltime
<Double>
Read-only
Average evaluation time of unsigned long type expression in nanoseconds.
pitrefevaltime
<Double>
Read-only
Average evaluation time of string type expression in nanoseconds.
pitoffsetevaltime
<Double>
Read-only
Average evaluation time in finding offset of the resultant string in the input. Time is in nanoseconds.
pitactionevaltime
<Double>
Read-only
Average evaluation time of rewrite action in nanoseconds.
pitoperationperformerarray
<String[]>
Read-only
Details of the operation NS performed at various offsets during applying of rewrite action on input data. Operation can be insertion, modfication or deletion.
Possible values = INSERT, MODIFY, DELETE
pitoldoffsetarray
<Double[]>
Read-only
Details of the offsets in the input data at which NS either inserted or modified or deleted data during applying of rewrite action.
pitnewoffsetarray
<Double[]>
Read-only
Details of the offsets in the output data at which NS either inserted or modified or deleted data during applying of rewrite action.
pitoffsetlengtharray
<Integer[]>
Read-only
Details of the lengths of the data which NS either inserted or modified or deleted during applying of rewrite action.
pitboolerrorresult
<String>
Read-only
Result of the bool type expression if any error occurs during evaluation. Result will be in string format.
pitnumerrorresult
<String>
Read-only
Result of the num type expression if any error occurs during evaluation. Result will be in string format.
pitdoubleerrorresult
<String>
Read-only
Result of the double type expression if any error occurs during evaluation. Result will be in string format.
pitulongerrorresult
<String>
Read-only
Result of the unsigned long type expression if any error occurs during evaluation. Result will be in string format.
pitreferrorresult
<String>
Read-only
Result of the ref type expression if any error occurs during evaluation. Result will be in string format.
pitoffseterrorresult
<String>
Read-only
Result of the expression if any error occurs in calculating offset. Result will be in string format.
pitactionerrorresult
<String>
Read-only
Result of the action if any error occurs in evaluation. Result will be in string format.
__count
<Double>
Read-only
count parameter

Operations (click to see Properties)

Some options that you can use for each operations:

  • Getting warnings in response: NITRO allows you to get warnings in an operation by specifying the "warning" query parameter as "yes". For example, to get warnings while connecting to the NetScaler appliance, the URL is as follows:

    http://<netscaler-ip-address>/nitro/v1/config/login?warning=yes

    If any, the warnings are displayed in the response payload with the HTTP code "209 X-NITRO-WARNING".

  • Authenticated access for individual NITRO operations: NITRO allows you to logon to the NetScaler appliance to perform individual operations. You can use this option instead of creating a NITRO session (using the login object) and then using that session to perform all operations,

    To do this, you must specify the username and password in the request header of the NITRO request as follows:

    X-NITRO-USER:<username>

    X-NITRO-PASS:<password>

    Note: In such cases, make sure that the request header DOES not include the following:

    Cookie:NITRO_AUTH_TOKEN=<tokenvalue>

메모

Mandatory parameters are marked in red and placeholder content is marked in <green>.

get (all)

URL: http://<netscaler-ip-address>/nitro/v1/config/policyevaluation

Query-parameters:

args

http://<netscaler-ip-address>/nitro/v1/config/policyevaluation?args=expression:<String_value>,action:<String_value>,type:<String_value>,input:<String_value>,

Use this query-parameter to get policyevaluation resources based on additional properties.

attrs

http://<netscaler-ip-address>/nitro/v1/config/policyevaluation?attrs=property-name1,property-name2

Use this query parameter to specify the resource details that you want to retrieve.

filter

http://<netscaler-ip-address>/nitro/v1/config/policyevaluation?filter=property-name1:property-val1,property-name2:property-val2

Use this query-parameter to get the filtered set of policyevaluation resources configured on NetScaler.Filtering can be done on any of the properties of the resource.

view

http://<netscaler-ip-address>/nitro/v1/config/policyevaluation?view=summary

Note: By default, the retrieved results are displayed in detail view (?view=detail).

pagination

http://<netscaler-ip-address>/nitro/v1/config/policyevaluation?pagesize=#no&pageno=#no

Use this query-parameter to get the policyevaluation resources in chunks.

HTTP Method: GET

Request Headers:

Cookie:NITRO_AUTH_TOKEN=<tokenvalue>
Accept:application/json

Response:

HTTP Status Code on Success: 200 OK
HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error

Response Headers:

Content-Type:application/json

Response Payload:

{ "policyevaluation": [ {
expression:<String_value>,action:<String_value>,type:<String_value>,input:<String_value>,      "pitmodifiedinputdata":<String_value>,
      "pitboolresult":<Boolean_value>,
      "pitnumresult":<Double_value>,
      "pitdoubleresult":<Double_value>,
      "pitulongresult":<Double_value>,
      "pitrefresult":<String_value>,
      "pitoffsetresult":<Double_value>,
      "pitoffsetresultlen":<Double_value>,
      "istruncatedrefresult":<Boolean_value>,
      "pitboolevaltime":<Double_value>,
      "pitnumevaltime":<Double_value>,
      "pitdoubleevaltime":<Double_value>,
      "pitulongevaltime":<Double_value>,
      "pitrefevaltime":<Double_value>,
      "pitoffsetevaltime":<Double_value>,
      "pitactionevaltime":<Double_value>,
      "pitoperationperformerarray":<String[]_value>,
      "pitoldoffsetarray":<Double[]_value>,
      "pitnewoffsetarray":<Double[]_value>,
      "pitoffsetlengtharray":<Integer[]_value>,
      "pitboolerrorresult":<String_value>,
      "pitnumerrorresult":<String_value>,
      "pitdoubleerrorresult":<String_value>,
      "pitulongerrorresult":<String_value>,
      "pitreferrorresult":<String_value>,
      "pitoffseterrorresult":<String_value>,
      "pitactionerrorresult":<String_value>
}]}

count

URL: http://<netscaler-ip-address>/nitro/v1/config/policyevaluation?args=expression:<String_value>,action:<String_value>,type:<String_value>,input:<String_value>,&count=yes

HTTP Method: GET

Request Headers:

Cookie:NITRO_AUTH_TOKEN=<tokenvalue>
Accept:application/json

Response:

HTTP Status Code on Success: 200 OK
HTTP Status Code on Failure: 4xx <string> (for general HTTP errors) or 5xx <string> (for NetScaler-specific errors). The response payload provides details of the error

Response Headers:

Content-Type:application/json

Response Payload:

{ "policyevaluation": [ { "__count": "#no"} ] }